diff --git a/.vs/WZC2_New/v17/.wsuo b/.vs/WZC2_New/v17/.wsuo new file mode 100644 index 000000000..2db6ad4cd Binary files /dev/null and b/.vs/WZC2_New/v17/.wsuo differ diff --git a/.vs/WZC2_New/v17/DocumentLayout.json b/.vs/WZC2_New/v17/DocumentLayout.json new file mode 100644 index 000000000..50c85d67a --- /dev/null +++ b/.vs/WZC2_New/v17/DocumentLayout.json @@ -0,0 +1,35 @@ +{ + "Version": 1, + "WorkspaceRootPath": "D:\\www\\WZC2_New\\", + "Documents": [], + "DocumentGroupContainers": [ + { + "Orientation": 1, + "VerticalTabListWidth": 256, + "DocumentGroups": [ + { + "DockedHeight": 200, + "SelectedChildIndex": -1, + "Children": [ + { + "$type": "Bookmark", + "Name": "ST:0:0:{1c4feeaa-4718-4aa9-859d-94ce25d182ba}" + }, + { + "$type": "Bookmark", + "Name": "ST:128:0:{116d2292-e37d-41cd-a077-ebacac4c8cc4}" + }, + { + "$type": "Bookmark", + "Name": "ST:129:0:{116d2292-e37d-41cd-a077-ebacac4c8cc4}" + }, + { + "$type": "Bookmark", + "Name": "ST:128:0:{1fc202d4-d401-403c-9834-5b218574bb67}" + } + ] + } + ] + } + ] +} \ No newline at end of file diff --git a/.vs/slnx.sqlite b/.vs/slnx.sqlite new file mode 100644 index 000000000..b0754f55c Binary files /dev/null and b/.vs/slnx.sqlite differ diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/DataExchangeDapperFawtygModule.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/DataExchangeDapperFawtygModule.cs index 237e0dcf6..93c8a6cae 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/DataExchangeDapperFawtygModule.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/DataExchangeDapperFawtygModule.cs @@ -11,6 +11,8 @@ using Win_in.Sfs.Wms.DataExchange.LinqToDB.Fawtyg.Tyrp.Boms; using Win_in.Sfs.Wms.DataExchange.LinqToDB.Fawtyg.Tyrp.Customers; using Win_in.Sfs.Wms.DataExchange.LinqToDB.Fawtyg.Tyrp.Dictpjs; using Win_in.Sfs.Wms.DataExchange.LinqToDB.Fawtyg.Tyrp.Products; +using Win_in.Sfs.Wms.DataExchange.LinqToDB.Fawtyg.Tyrp.PurchasePrices; +using Win_in.Sfs.Wms.DataExchange.LinqToDB.Fawtyg.Tyrp.SalePrices; using Win_in.Sfs.Wms.DataExchange.LinqToDB.Fawtyg.Tyrp.Venders; namespace Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp; @@ -45,5 +47,7 @@ public class DataExchangeDapperFawtygModule : AbpModule context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); + context.Services.AddTransient(); + context.Services.AddTransient(); } } diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/PurchasePrices/PurchasePriceLinq2DbRepository.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/PurchasePrices/PurchasePriceLinq2DbRepository.cs new file mode 100644 index 000000000..798d16e4c --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/PurchasePrices/PurchasePriceLinq2DbRepository.cs @@ -0,0 +1,14 @@ +using Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp; +using Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp.Bases; +using Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; + +namespace Win_in.Sfs.Wms.DataExchange.LinqToDB.Fawtyg.Tyrp.PurchasePrices; +public class PurchasePriceLinq2DbRepository : + Linq2DbCrudRepository, + IPurchasePriceLinq2DbRepository +{ + public PurchasePriceLinq2DbRepository(TyrpDb tyrpDb) : base(tyrpDb) + { + + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/SalePrices/SalePriceLinq2DbRepository.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/SalePrices/SalePriceLinq2DbRepository.cs new file mode 100644 index 000000000..3592a4604 --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/SalePrices/SalePriceLinq2DbRepository.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp.Bases; +using Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp; +using Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; + +namespace Win_in.Sfs.Wms.DataExchange.LinqToDB.Fawtyg.Tyrp.SalePrices; + +public class SalePriceLinq2DbRepository : + Linq2DbCrudRepository, + ISalePriceLinq2DbRepository +{ + public SalePriceLinq2DbRepository(TyrpDb tyrpDb) : base(tyrpDb) + { + + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/TyrpDb.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/TyrpDb.cs index cd66f0a1e..e59acea0b 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/TyrpDb.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Dapper.Fawtyg.Tyrp/TyrpDb.cs @@ -18,6 +18,8 @@ public class TyrpDb : DataConnection, ITransientDependency public ITable Supplier => this.GetTable(); public ITable Dictpj => this.GetTable(); public ITable Customer => this.GetTable(); + public ITable PurchasePrice => this.GetTable(); + public ITable SalePrice => this.GetTable(); public ITable Backflu => this.GetTable(); public ITable mes_product => this.GetTable(); diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/Products/mes_product.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/Products/mes_product.cs index 1e5e69dc1..49cc9042e 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/Products/mes_product.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/Products/mes_product.cs @@ -86,12 +86,18 @@ public class mes_product : Entity /// public string mes_product_active { get; set; } /// - /// + /// 最小領用倍數 /// - public string mes_product_qad01 { get; set; } - - // public string mes_product_fih_factory { get; set; } - + public decimal mes_product_qad01 { get; set; } + /// + /// 正廠編號 + /// + public string mes_product_fih_factory { get; set; } + /// + /// 标准成本 + /// + /// + public decimal mes_product_price_std { get; set; } public override object[] GetKeys() { return new object[] { mes_product_part_ser }; diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/IPurchasePriceLinq2DbRepository.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/IPurchasePriceLinq2DbRepository.cs new file mode 100644 index 000000000..288cd4216 --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/IPurchasePriceLinq2DbRepository.cs @@ -0,0 +1,10 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; +public interface IPurchasePriceLinq2DbRepository : ILinq2DbRepository +{ +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/IPurchasePriceManager.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/IPurchasePriceManager.cs new file mode 100644 index 000000000..bb8d17af9 --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/IPurchasePriceManager.cs @@ -0,0 +1,8 @@ +using System.Collections.Generic; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; +public interface IPurchasePriceManager +{ + Task> GetToBeProcessedListAsync(); +} \ No newline at end of file diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/PurchasePriceManager.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/PurchasePriceManager.cs new file mode 100644 index 000000000..9ffff750c --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/PurchasePriceManager.cs @@ -0,0 +1,23 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; + +namespace Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; +public class PurchasePriceManager : DomainService, IPurchasePriceManager +{ + private readonly IPurchasePriceLinq2DbRepository _repository; + public PurchasePriceManager(IPurchasePriceLinq2DbRepository repository) + { + _repository = repository; + } + + public async Task> GetToBeProcessedListAsync() + { + var purchaseprice = await _repository.GetListAsync().ConfigureAwait(false); + return purchaseprice.ToList(); + } +} + diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/ismout.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/ismout.cs new file mode 100644 index 000000000..3c070a6f9 --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/PurchasePrices/ismout.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Volo.Abp.Domain.Entities; + +namespace Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; +/// +/// 采购价格 +/// +public class ismout : Entity +{ + /// + /// 物料代码 + /// + public string ismout_part { get; set; } + + /// + /// 供应商代码 + /// + public string ismout_vend { get; set; } + + /// + /// 采购价格 + /// + public decimal ismout_price { get; set; } + + public override object[] GetKeys() + { + return new object[] { ismout_part, ismout_vend }; + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/ISalePriceLinq2DbRepository.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/ISalePriceLinq2DbRepository.cs new file mode 100644 index 000000000..d0872925b --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/ISalePriceLinq2DbRepository.cs @@ -0,0 +1,10 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; +public interface ISalePriceLinq2DbRepository : ILinq2DbRepository +{ +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/ISalePriceManager.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/ISalePriceManager.cs new file mode 100644 index 000000000..7e7b877e5 --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/ISalePriceManager.cs @@ -0,0 +1,8 @@ +using System.Collections.Generic; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; +public interface ISalePriceManager +{ + Task> GetToBeProcessedListAsync(); +} \ No newline at end of file diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/SalePriceManager.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/SalePriceManager.cs new file mode 100644 index 000000000..b95ea2e22 --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/SalePriceManager.cs @@ -0,0 +1,23 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; + +namespace Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; + +public class SalePriceManager : DomainService, ISalePriceManager +{ + private readonly ISalePriceLinq2DbRepository _repository; + public SalePriceManager(ISalePriceLinq2DbRepository repository) + { + _repository = repository; + } + + public async Task> GetToBeProcessedListAsync() + { + var saleprice = await _repository.GetListAsync().ConfigureAwait(false); + return saleprice.ToList(); + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/spriceout.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/spriceout.cs new file mode 100644 index 000000000..d0bc15c7a --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp/SalePrices/spriceout.cs @@ -0,0 +1,33 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Volo.Abp.Domain.Entities; + +namespace Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; +/// +/// 销售价格 +/// +public class spriceout : Entity +{ + /// + /// 物料代码 + /// + public string spriceout_part { get; set; } + + /// + /// 客户代码 + /// + public string spriceout_cust { get; set; } + + /// + /// 销售价格 + /// + public decimal spriceout_price { get; set; } + + public override object[] GetKeys() + { + return new object[] { spriceout_part, spriceout_cust }; + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/FawtygAutoMapperProfile.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/FawtygAutoMapperProfile.cs index a4d163e2a..c925bd78e 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/FawtygAutoMapperProfile.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/FawtygAutoMapperProfile.cs @@ -86,7 +86,7 @@ public class FawtygAutoMapperProfile : Profile CreateMap() .ForMember(x => x.Code, y => y.MapFrom(d => d.PackingCode)) - .ForMember(x => x.LabelType, y => y.MapFrom(d => EnumLabelType.PurchaseLabel)) + .ForMember(x => x.LabelType, y => y.MapFrom(d => Label.Domain.Shared.EnumLabelType.PurchaseLabel)) .ForMember(x => x.LabelStatus, y => y.MapFrom(d => LabelStatus.Enable)) .Ignore(x => x.FullBarcodeString) .Ignore(x => x.RecommendLocationCode) diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/Incoming/PlanReader.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/Incoming/PlanReader.cs index 296063800..0d9bc033f 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/Incoming/PlanReader.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/Incoming/PlanReader.cs @@ -5,6 +5,7 @@ using System.Text.Json; using System.Threading.Tasks; using Microsoft.Extensions.Logging; using Volo.Abp.Guids; +using Win_in.Sfs.Basedata.Application.Contracts; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.DataExchange.Domain; using Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.EOS; @@ -20,17 +21,20 @@ public class PlanReader : IReader private readonly IIncomingFromExternalManager _incomingFromExternalManager; private readonly ILogger _logger; private readonly IGuidGenerator _guidGenerator; + private readonly IPurchasePriceSheetAppService _purchasePriceSheetAppService; public PlanReader( IPlanManager planManager , IIncomingFromExternalManager incomingFromExternalManager , ILogger logger - , IGuidGenerator guidGenerator + , IGuidGenerator guidGenerator, + IPurchasePriceSheetAppService purchasePriceSheetAppService ) { _planManager = planManager; _incomingFromExternalManager = incomingFromExternalManager; _logger = logger; _guidGenerator = guidGenerator; + _purchasePriceSheetAppService = purchasePriceSheetAppService; } @@ -43,6 +47,12 @@ public class PlanReader : IReader _logger.LogInformation("no plans"); return new List(); } + var pobillno = await GetPriceItems(toBeProcessedPlans).ConfigureAwait(false); + if (pobillno.Count > 0) + { + toBeProcessedPlans = toBeProcessedPlans.Where(r => !pobillno.Contains(r.PlanBillNo)).ToList(); + } + //Plan逐一转换为PurchaseOrder var incomingDataList = BuildIncomingFromExternalFromPlanAsync(toBeProcessedPlans); await _incomingFromExternalManager.CreateBulkAsync(incomingDataList).ConfigureAwait(false); @@ -50,7 +60,22 @@ public class PlanReader : IReader await _planManager.UpdateProcessedListAsync(toBeProcessedPlans).ConfigureAwait(false); return incomingDataList; } + private async Task> GetPriceItems(List toBeProcessedPlans) + { + List pobillno = new List(); + foreach (var plan in toBeProcessedPlans) + { + if (pobillno.Contains(plan.PlanBillNo)) continue; + var price = await _purchasePriceSheetAppService.GetByItemCodeAsync(plan.ERP,plan.SupplierCode).ConfigureAwait(false); + if (price == null) + { + pobillno.Add(plan.PlanBillNo); + } + + } + return pobillno; + } private List BuildIncomingFromExternalFromPlanAsync(List toBeProcessedPlans) { var incomingDataList = new List(); @@ -109,9 +134,10 @@ public class PlanReader : IReader OrderDate = plan.ReleaseDate, DueDate = plan.PlanArriveDate, ContactName = plan.PlanUserCode, - OrderStatus = plan.PlanBillState == 0 - ? EnumOrderStatus.Open - : EnumOrderStatus.Close, + //OrderStatus = plan.PlanBillState == 0 + // ? EnumOrderStatus.Open + // : EnumOrderStatus.Close, + OrderStatus= EnumOrderStatus.Open, ActiveDate = plan.EosDate, Worker = plan.PlanUserCode, // PoType = "2", diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/Incoming/ShipReader.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/Incoming/ShipReader.cs index d32b3838b..a27f4d930 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/Incoming/ShipReader.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent/Incoming/ShipReader.cs @@ -11,6 +11,7 @@ using Win_in.Sfs.Wms.DataExchange.Domain; using Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.EOS; using Win_in.Sfs.Wms.DataExchange.Domain.Shared; using Win_in.Sfs.Wms.DataExchange.WMS.SuppplierAsn; +using Win_in.Sfs.Wms.Store.Application.Contracts; namespace Win_in.Sfs.Wms.DataExchange.Fawtyg.EosAgent; @@ -22,12 +23,14 @@ public class ShipReader : IReader private readonly ILogger _logger; private readonly ISupplierItemAppService _supplierItemAppService; private readonly ISupplierAppService _supplierAppService; + private readonly IPurchaseOrderAppService _purchaseOrderAppService; public ShipReader( IShipManager shipManager , IIncomingFromExternalManager incomingFromExternalManager , ILogger logger, ISupplierItemAppService supplierItemAppService, - ISupplierAppService supplierAppService + ISupplierAppService supplierAppService, + IPurchaseOrderAppService purchaseOrderAppService ) { _shipManager = shipManager; @@ -35,6 +38,7 @@ public class ShipReader : IReader _logger = logger; _supplierItemAppService = supplierItemAppService; _supplierAppService = supplierAppService; + _purchaseOrderAppService=purchaseOrderAppService; } public virtual async Task> ReadAsync() @@ -52,6 +56,13 @@ public class ShipReader : IReader { toBeProcessedShips = toBeProcessedShips.Where(r => !shipbillno.Contains(r.ShipBillNo)).ToList(); } + //排除没有订单号的收货单(被排出的下次同步) + var pobilllist= toBeProcessedShips.Select(r => r.PlanBillNo).Distinct().ToList(); + var ponumber =await _purchaseOrderAppService.GetNoPoBillList(pobilllist).ConfigureAwait(false); + if(ponumber.Count > 0) + { + toBeProcessedShips = toBeProcessedShips.Where(r => !ponumber.Contains(r.PlanBillNo)).ToList(); + } //Ship逐一转换为SupplierAsn var incomingDataList = await BuildIncomingFromExternalFromShipAsync(toBeProcessedShips).ConfigureAwait(false); await _incomingFromExternalManager.CreateManyAsync(incomingDataList).ConfigureAwait(false); diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/Incoming/MesOutConverter.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/Incoming/MesOutConverter.cs index c02ec3312..941cc6cb4 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/Incoming/MesOutConverter.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/Incoming/MesOutConverter.cs @@ -6,10 +6,12 @@ using System.Threading.Tasks; using Microsoft.Extensions.Configuration; using Microsoft.Extensions.Logging; using Org.BouncyCastle.Asn1.Pkcs; +using Volo.Abp.Data; using Volo.Abp.ObjectMapping; using Win_in.Sfs.Basedata.Application.Contracts; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.DataExchange.Domain; +using Win_in.Sfs.Wms.DataExchange.Domain.Shared; using Win_in.Sfs.Wms.DataExchange.WMS.ProductReceiptNote; using Win_in.Sfs.Wms.Store.Application.Contracts; using Win_in.Sfs.Wms.Store.Domain; @@ -62,7 +64,7 @@ public class MesOutConverter : IIncomingConverter { List types = new List { EnumLocationType.FG, EnumLocationType.WIP }; var incomingToWmsList = new List(); - var groups = incomingDataList.GroupBy(p => p.SourceDataGroupCode); + var groups = incomingDataList.GroupBy(p => new { p.SourceDataGroupCode, p.TableType });//按照库位和是为为返喷分组 foreach (var group in groups) { var first = group.First(); @@ -80,15 +82,26 @@ public class MesOutConverter : IIncomingConverter wmsProductReceiptNote.Worker = "MES";//操作人 wmsProductReceiptNote.ReceiptType = EnumReceiptType.MesScanReceipt;//完工收货方式 wmsProductReceiptNote.Details = new List(); - + List sumDetails = new List(); foreach (var incomingFromExternal in group.ToList()) { + ProductReceiptNoteSumDetailExchangeDto sumdetail = new ProductReceiptNoteSumDetailExchangeDto(); var productReceiptNote = JsonSerializer.Deserialize(incomingFromExternal.DestinationDataContent); var wmsProductReceiptNoteDetail = _objectMapper.Map(productReceiptNote.Detail); - var oldNoteDetail= wmsProductReceiptNote.Details.FirstOrDefault(r => r.ItemCode == wmsProductReceiptNoteDetail.ItemCode && r.LocationErpCode == wmsProductReceiptNoteDetail.LocationErpCode); + + var oldNoteDetail = wmsProductReceiptNote.Details.FirstOrDefault(r => r.ItemCode == wmsProductReceiptNoteDetail.ItemCode && r.LocationErpCode == wmsProductReceiptNoteDetail.LocationErpCode && (first.TableType != EnumExchangeTableType.MainTable ? true : r.ReturnQty != 0)); + + sumdetail.itemCode = wmsProductReceiptNoteDetail.ItemCode; + sumdetail.locationCode = wmsProductReceiptNoteDetail.LocationErpCode; + sumdetail.Qty = wmsProductReceiptNoteDetail.Qty; + sumdetail.BadQty = wmsProductReceiptNoteDetail.ReturnQty; + sumdetail.Memo = wmsProductReceiptNoteDetail.Remark; + sumdetail.MesGuid = incomingFromExternal.SourceDataId; + sumDetails.Add(sumdetail); if (oldNoteDetail != null) { - oldNoteDetail.Qty = oldNoteDetail.Qty+wmsProductReceiptNoteDetail.Qty; + oldNoteDetail.Qty = oldNoteDetail.Qty + wmsProductReceiptNoteDetail.Qty; + oldNoteDetail.ReturnQty = oldNoteDetail.ReturnQty + wmsProductReceiptNoteDetail.ReturnQty; } else { @@ -141,6 +154,8 @@ public class MesOutConverter : IIncomingConverter wmsProductReceiptNote.Details.Add(wmsProductReceiptNoteDetail); } } + wmsProductReceiptNote.ExtraProperties = new ExtraPropertyDictionary(); + wmsProductReceiptNote.ExtraProperties.Add(first.SourceDataGroupCode, JsonSerializer.Serialize(sumDetails)); incomingToWms.DataContent = JsonSerializer.Serialize(wmsProductReceiptNote); incomingToWmsList.Add(incomingToWms); } diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/Incoming/MesOutReader.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/Incoming/MesOutReader.cs index 10845124b..f0171be9c 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/Incoming/MesOutReader.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/Incoming/MesOutReader.cs @@ -36,7 +36,7 @@ public class MesOutReader : IReader { //从MES读取待处理MesOut var toBeProcessedMwsOuts = await _mesOutManager.GetToBeProcessedListAsync().ConfigureAwait(false); - toBeProcessedMwsOuts = toBeProcessedMwsOuts.OrderBy(r=>r.Mesout_dt).Take(3000).ToList(); + toBeProcessedMwsOuts = toBeProcessedMwsOuts.OrderBy(r => r.Mesout_dt).Take(3000).ToList(); if (!toBeProcessedMwsOuts.Any()) { _logger.LogInformation("no productreceipts"); @@ -46,8 +46,8 @@ public class MesOutReader : IReader if (mesoutnbr.Count > 0) { toBeProcessedMwsOuts = toBeProcessedMwsOuts.Where(r => !mesoutnbr.Contains(r.Mesout_ref_nbr)).ToList(); - var toBeProcessedEroMwsOuts = toBeProcessedMwsOuts.Where(r => mesoutnbr.Contains(r.Mesout_ref_nbr)).ToList(); - + var toBeProcessedEroMwsOuts = toBeProcessedMwsOuts.Where(r => mesoutnbr.Contains(r.Mesout_ref_nbr)).ToList(); + await _mesOutManager.UpdateProcesseErrordListAsync(toBeProcessedEroMwsOuts).ConfigureAwait(false); } //MesOut逐一转换为ProductReceiptNote @@ -55,7 +55,7 @@ public class MesOutReader : IReader await _incomingFromExternalManager.CreateManyAsync(incomingDataList).ConfigureAwait(false); //更新MES数据状态 await _mesOutManager.UpdateProcessedListAsync(toBeProcessedMwsOuts).ConfigureAwait(false); - + return incomingDataList; } @@ -119,6 +119,11 @@ public class MesOutReader : IReader DestinationSystem = EnumSystemType.WMS.ToString(), }; + //返喷数不为零用tabletype标志出来,用于后续汇总 + if (mesOut.Mesout_bad != 0) + { + incomingData.TableType = EnumExchangeTableType.MainTable; + } return incomingData; } @@ -136,7 +141,7 @@ public class MesOutReader : IReader Qty = mesOut.Mesout_move, LocationErpCode = mesOut.Mesout_loc, Remark = mesOut.memo, - ReturnQty=mesOut.Mesout_bad + ReturnQty = mesOut.Mesout_bad }; productReceiptNote.Detail = productReceiptNoteDetail; return productReceiptNote; diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/appsettings.json b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/appsettings.json index 865028c94..a5a6cb1d9 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/appsettings.json +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.MesAgent/appsettings.json @@ -1,8 +1,8 @@ { "ConnectionStrings": { - "Default": "Server=10.164.113.32,1818\\SHDB;Database=Wms_Dy_ShangHai;uid=ShWmsUser;pwd=Faty@Wms_20230413#SH;TrustServerCertificate=True", - "DataExchange": "Server=10.164.113.32,1818\\SHDB;Database=Wms_DataExchange_Main_Dy_ShangHai;uid=ShWmsUser;pwd=Faty@Wms_20230413#SH;TrustServerCertificate=True", - "MES": "Server=10.164.113.32,1818\\SHDB;Database=MES_SH;uid=ShWmsUser;pwd=Faty@Wms_20230413#SH;TrustServerCertificate=True" + "Default": "Server=10.164.113.32,1818\\SHDB;Database=Wms_Dy_ShangHai;uid=ShWmsUser;pwd=Faty@Wms_20230413#SH;TrustServerCertificate=True;Encrypt=false", + "DataExchange": "Server=10.164.113.32,1818\\SHDB;Database=Wms_DataExchange_Main_Dy_ShangHai;uid=ShWmsUser;pwd=Faty@Wms_20230413#SH;TrustServerCertificate=True;Encrypt=false", + "MES": "Server=10.164.113.32,1818\\SHDB;Database=MES_SH;uid=ShWmsUser;pwd=Faty@Wms_20230413#SH;TrustServerCertificate=True;Encrypt=false" }, "AuthServer": { diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/FawtygAutoMapperProfile.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/FawtygAutoMapperProfile.cs index 0e7b7064d..8cbc197bb 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/FawtygAutoMapperProfile.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/FawtygAutoMapperProfile.cs @@ -20,10 +20,13 @@ using Win_in.Sfs.Wms.DataExchange.WMS.ProductionReturnNote; using Win_in.Sfs.Wms.DataExchange.WMS.ProductReceiptNote; using Win_in.Sfs.Wms.DataExchange.WMS.ProductRecycleNote; using Win_in.Sfs.Wms.DataExchange.WMS.PurchaseOrder; +using Win_in.Sfs.Wms.DataExchange.WMS.PurchasePrice; using Win_in.Sfs.Wms.DataExchange.WMS.PurchaseReturn; using Win_in.Sfs.Wms.DataExchange.WMS.PutawayNote; using Win_in.Sfs.Wms.DataExchange.WMS.RecycledMaterialReceiptNote; +using Win_in.Sfs.Wms.DataExchange.WMS.SalePrice; using Win_in.Sfs.Wms.DataExchange.WMS.ScrapNote; +using Win_in.Sfs.Wms.DataExchange.WMS.StdCostPrice; using Win_in.Sfs.Wms.DataExchange.WMS.Supplier; using Win_in.Sfs.Wms.DataExchange.WMS.TransferNote; using Win_in.Sfs.Wms.DataExchange.WMS.UnplannedIssueNote; @@ -107,6 +110,9 @@ public class FawtygAutoMapperProfile : Profile CreateMap(); CreateMap(); CreateMap(); + CreateMap(); + CreateMap(); + CreateMap(); CreateMap(); CreateMap(); diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/PurchasePriceConverter.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/PurchasePriceConverter.cs new file mode 100644 index 000000000..90e8ebcf0 --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/PurchasePriceConverter.cs @@ -0,0 +1,75 @@ +using System.Collections.Generic; +using System.Linq; +using System.Text.Json; +using System.Threading.Tasks; +using Microsoft.Extensions.Logging; +using Volo.Abp.Guids; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Wms.DataExchange.Domain; +using Win_in.Sfs.Wms.DataExchange.WMS.PurchasePrice; + +namespace Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent.Incoming; + +public class PurchasePriceConverter : IIncomingConverter +{ + private readonly IIncomingToWmsManager _incomingToWmsManager; + private readonly IObjectMapper _objectMapper; + private readonly ILogger _logger; + private readonly IGuidGenerator _guidGenerator; + private readonly IIncomingFromExternalManager _incomingFromExternalManager; + + public PurchasePriceConverter( + IIncomingToWmsManager incomingToWmsManager, + IObjectMapper objectMapper, + ILogger logger, + IGuidGenerator guidGenerator +, + IIncomingFromExternalManager incomingFromExternalManager + +) + { + _incomingToWmsManager = incomingToWmsManager; + _objectMapper = objectMapper; + _logger = logger; + _guidGenerator = guidGenerator; + _incomingFromExternalManager = incomingFromExternalManager; + } + public virtual async Task ConvertAsync(List incomingFromExternalList) + { + if (!incomingFromExternalList.Any()) + { + _logger.LogInformation("无采购价格转换"); + return; + } + var incomingToWmsDataList = await BuildIncomingToWmsOfPurchaseOrderAsync(incomingFromExternalList).ConfigureAwait(false); + await _incomingToWmsManager.CreateBulkAsync(incomingToWmsDataList).ConfigureAwait(false); + //归档 + await _incomingFromExternalManager.ArchiveManyAsync(incomingFromExternalList).ConfigureAwait(false); + + } + private async Task> BuildIncomingToWmsOfPurchaseOrderAsync(List incomingDataList) + { + await Task.CompletedTask.ConfigureAwait(false); + var incomingToWmsList = new List(); + var groups = incomingDataList.GroupBy(p => p.SourceDataGroupCode); + foreach (var group in groups) + { + var first = group.First(); + var incomingToWms = new IncomingToWms() + { + DataType = first.DataType, + DataAction = first.DataAction, + SourceSystem = first.SourceSystem, + DataIdentityCode = first.SourceDataGroupCode, + }; + incomingToWms.SetId(_guidGenerator.Create()); + incomingToWms.SetEffectiveDate(first.EffectiveDate); + var exchangePurchasePrice = JsonSerializer.Deserialize(first.DestinationDataContent); + var wmsPurchasePrice = _objectMapper.Map(exchangePurchasePrice); + incomingToWms.DataContent = JsonSerializer.Serialize(wmsPurchasePrice); + incomingToWmsList.Add(incomingToWms); + } + return incomingToWmsList; + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/PurchasePriceReader.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/PurchasePriceReader.cs new file mode 100644 index 000000000..b7f2a1305 --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/PurchasePriceReader.cs @@ -0,0 +1,133 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text.Json; +using System.Threading.Tasks; +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.Logging; +using Volo.Abp.Guids; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Wms.DataExchange.Domain; +using Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; +using Win_in.Sfs.Wms.DataExchange.Domain.Shared; +using Win_in.Sfs.Wms.DataExchange.WMS.PurchasePrice; + +namespace Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent.Incoming; + +public class PurchasePriceReader : IReader +{ + private readonly IPurchasePriceManager _iPurchasePriceManager; + private readonly IIncomingFromExternalManager _incomingFromExternalManager; + private readonly ILogger _logger; + private readonly IGuidGenerator _guidGenerator; + private readonly IConfiguration _configuration; + private readonly IPurchasePriceSheetAppService _purchasePriceAppService; + private readonly IObjectMapper _objectMapper; + public PurchasePriceReader( + IPurchasePriceManager iPurchasePriceManager + , IIncomingFromExternalManager incomingFromExternalManager + , IGuidGenerator guidGenerator + , ILogger logger + , IConfiguration configuration, + IPurchasePriceSheetAppService purchasePriceSheetAppService, + IObjectMapper objectMapper + ) + { + _guidGenerator = guidGenerator; + _configuration = configuration; + _iPurchasePriceManager = iPurchasePriceManager; + _incomingFromExternalManager = incomingFromExternalManager; + _logger = logger; + _purchasePriceAppService = purchasePriceSheetAppService; + _objectMapper = objectMapper; + } + + public virtual async Task> ReadAsync() + { + //从Tyrp读取待处理PurchasePrice + var toBeProcessedPurchasePrices = await _iPurchasePriceManager.GetToBeProcessedListAsync().ConfigureAwait(false); + if (!toBeProcessedPurchasePrices.Any()) + { + _logger.LogInformation("no PurchasePrices"); + return new List(); + } + //获取wms采购单价数据 + SfsBaseDataRequestInputBase input = new SfsBaseDataRequestInputBase(); + var wmsPurchasePrices = await _purchasePriceAppService.GetAllListByFilterAsync(input).ConfigureAwait(false); + var wmsToPurchasePriceExchangeDtos = _objectMapper.Map, List>(wmsPurchasePrices); + List eosToBomExchangeDtos = new List(); + foreach (var toBeProcessedPurchasePrice in toBeProcessedPurchasePrices) + { + var purchasePrice = BuildScrapNoteOrderExchangeMes(toBeProcessedPurchasePrice); + eosToBomExchangeDtos.Add(purchasePrice); + } + //和wms和eos数据进行比较,获取需要处理得数据 + var updateDatas = eosToBomExchangeDtos.Except(wmsToPurchasePriceExchangeDtos).ToList(); + if (!updateDatas.Any()) + { + _logger.LogInformation("no PurchasePrices"); + return new List(); + } + //PurchasePrice逐一转换为PurchasePrice + var incomingDataList = BuildIncomingFromExternalFromBomAsync(updateDatas, toBeProcessedPurchasePrices); + await _incomingFromExternalManager.CreateBulkAsync(incomingDataList).ConfigureAwait(false); + return incomingDataList; + } + private List BuildIncomingFromExternalFromBomAsync(List updateDatas,List toBeProcessedPurchasePrices) + { + var incomingDataList = new List(); + foreach (var data in updateDatas) + { + var item = toBeProcessedPurchasePrices.FirstOrDefault(r => r.ismout_part == data.ItemCode && r.ismout_vend == data.SupplierCode); + var incomingData = BuildIncomingFromExternal(item); + + incomingData.SetEffectiveDate(DateTime.Now); + + try + { + incomingData.DestinationDataContent = JsonSerializer.Serialize(data); + incomingData.SetId(_guidGenerator.Create()); + } + catch (Exception ex) + { + incomingData.SetError(EnumExchangeDataErrorCode.Exception, ex.Message, ex.ToString()); + } + + incomingDataList.Add(incomingData); + + } + return incomingDataList; + } + private IncomingFromExternal BuildIncomingFromExternal(ismout PurchasePrice) + { + var incomingData = new IncomingFromExternal() + { + + DataType = EnumIncomingDataType.PurchasePrice.ToString(), + DataAction = EnumExchangeDataAction.Add, + SourceSystem = EnumSystemType.ERP.ToString(), + SourceDataId = PurchasePrice.ismout_part, + SourceDataGroupCode = PurchasePrice.ismout_part, + SourceDataDetailCode = PurchasePrice.ismout_vend, + SourceDataContent = JsonSerializer.Serialize(PurchasePrice), + WriteTime = DateTime.Now, + Writer = nameof(TyrpIncomingBackgroundWorker), + DestinationSystem = EnumSystemType.ERP.ToString(), + }; + return incomingData; + } + + private static PurchasePriceExchangeDto BuildScrapNoteOrderExchangeMes(ismout PurchasePrice) + { + + var price = new PurchasePriceExchangeDto() + { + ItemCode = PurchasePrice.ismout_part, + SupplierCode = PurchasePrice.ismout_vend, + PurchasePrice = PurchasePrice.ismout_price, + Description = "接口同步", + }; + return price; + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/SalePriceConverter.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/SalePriceConverter.cs new file mode 100644 index 000000000..9c85f08ce --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/SalePriceConverter.cs @@ -0,0 +1,74 @@ +using System.Collections.Generic; +using System.Linq; +using System.Text.Json; +using System.Threading.Tasks; +using Microsoft.Extensions.Logging; +using Volo.Abp.Guids; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Wms.DataExchange.Domain; +using Win_in.Sfs.Wms.DataExchange.WMS.SalePrice; + +namespace Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent.Incoming; +public class SalePriceConverter : IIncomingConverter +{ + private readonly IIncomingToWmsManager _incomingToWmsManager; + private readonly IObjectMapper _objectMapper; + private readonly ILogger _logger; + private readonly IGuidGenerator _guidGenerator; + private readonly IIncomingFromExternalManager _incomingFromExternalManager; + + public SalePriceConverter( + IIncomingToWmsManager incomingToWmsManager, + IObjectMapper objectMapper, + ILogger logger, + IGuidGenerator guidGenerator +, + IIncomingFromExternalManager incomingFromExternalManager + +) + { + _incomingToWmsManager = incomingToWmsManager; + _objectMapper = objectMapper; + _logger = logger; + _guidGenerator = guidGenerator; + _incomingFromExternalManager = incomingFromExternalManager; + } + public virtual async Task ConvertAsync(List incomingFromExternalList) + { + if (!incomingFromExternalList.Any()) + { + _logger.LogInformation("无销售价格转换"); + return; + } + var incomingToWmsDataList = await BuildIncomingToWmsOfPurchaseOrderAsync(incomingFromExternalList).ConfigureAwait(false); + await _incomingToWmsManager.CreateBulkAsync(incomingToWmsDataList).ConfigureAwait(false); + //归档 + await _incomingFromExternalManager.ArchiveManyAsync(incomingFromExternalList).ConfigureAwait(false); + + } + private async Task> BuildIncomingToWmsOfPurchaseOrderAsync(List incomingDataList) + { + await Task.CompletedTask.ConfigureAwait(false); + var incomingToWmsList = new List(); + var groups = incomingDataList.GroupBy(p => p.SourceDataGroupCode); + foreach (var group in groups) + { + var first = group.First(); + var incomingToWms = new IncomingToWms() + { + DataType = first.DataType, + DataAction = first.DataAction, + SourceSystem = first.SourceSystem, + DataIdentityCode = first.SourceDataGroupCode, + }; + incomingToWms.SetId(_guidGenerator.Create()); + incomingToWms.SetEffectiveDate(first.EffectiveDate); + var exchangeSalePrice = JsonSerializer.Deserialize(first.DestinationDataContent); + var wmsSalePrice = _objectMapper.Map(exchangeSalePrice); + incomingToWms.DataContent = JsonSerializer.Serialize(wmsSalePrice); + incomingToWmsList.Add(incomingToWms); + } + return incomingToWmsList; + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/SalePriceReader.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/SalePriceReader.cs new file mode 100644 index 000000000..e44190ea5 --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/SalePriceReader.cs @@ -0,0 +1,132 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text.Json; +using System.Threading.Tasks; +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.Logging; +using Volo.Abp.Guids; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Wms.DataExchange.Domain; +using Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; +using Win_in.Sfs.Wms.DataExchange.Domain.Shared; +using Win_in.Sfs.Wms.DataExchange.WMS.SalePrice; + +namespace Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent.Incoming; +public class SalePriceReader : IReader +{ + private readonly ISalePriceManager _iSalePriceManager; + private readonly IIncomingFromExternalManager _incomingFromExternalManager; + private readonly ILogger _logger; + private readonly IGuidGenerator _guidGenerator; + private readonly IConfiguration _configuration; + private readonly ISalePriceSheetAppService _SalePriceAppService; + private readonly IObjectMapper _objectMapper; + public SalePriceReader( + ISalePriceManager iSalePriceManager + , IIncomingFromExternalManager incomingFromExternalManager + , IGuidGenerator guidGenerator + , ILogger logger + , IConfiguration configuration, + ISalePriceSheetAppService SalePriceSheetAppService, + IObjectMapper objectMapper + ) + { + _guidGenerator = guidGenerator; + _configuration = configuration; + _iSalePriceManager = iSalePriceManager; + _incomingFromExternalManager = incomingFromExternalManager; + _logger = logger; + _SalePriceAppService = SalePriceSheetAppService; + _objectMapper = objectMapper; + } + + public virtual async Task> ReadAsync() + { + //从Tyrp读取待处理SalePrice + var toBeProcessedSalePrices = await _iSalePriceManager.GetToBeProcessedListAsync().ConfigureAwait(false); + if (!toBeProcessedSalePrices.Any()) + { + _logger.LogInformation("no SalePrices"); + return new List(); + } + //获取wms销售单价数据 + SfsBaseDataRequestInputBase input = new SfsBaseDataRequestInputBase(); + var wmsSalePrices = await _SalePriceAppService.GetAllListByFilterAsync(input).ConfigureAwait(false); + var wmsToSalePriceExchangeDtos = _objectMapper.Map, List>(wmsSalePrices); + List eosToBomExchangeDtos = new List(); + foreach (var toBeProcessedSalePrice in toBeProcessedSalePrices) + { + var SalePrice = BuildScrapNoteOrderExchangeMes(toBeProcessedSalePrice); + eosToBomExchangeDtos.Add(SalePrice); + } + //和wms和eos数据进行比较,获取需要处理得数据 + var updateDatas = eosToBomExchangeDtos.Except(wmsToSalePriceExchangeDtos).ToList(); + if (!updateDatas.Any()) + { + _logger.LogInformation("no SalePrices"); + return new List(); + } + //SalePrice逐一转换为SalePrice + var incomingDataList = BuildIncomingFromExternalFromBomAsync(updateDatas, toBeProcessedSalePrices); + await _incomingFromExternalManager.CreateBulkAsync(incomingDataList).ConfigureAwait(false); + return incomingDataList; + } + private List BuildIncomingFromExternalFromBomAsync(List updateDatas, List toBeProcessedSalePrices) + { + var incomingDataList = new List(); + foreach (var data in updateDatas) + { + var item = toBeProcessedSalePrices.FirstOrDefault(r => r.spriceout_part == data.ItemCode && r.spriceout_cust == data.CustomerCode); + var incomingData = BuildIncomingFromExternal(item); + + incomingData.SetEffectiveDate(DateTime.Now); + + try + { + incomingData.DestinationDataContent = JsonSerializer.Serialize(data); + incomingData.SetId(_guidGenerator.Create()); + } + catch (Exception ex) + { + incomingData.SetError(EnumExchangeDataErrorCode.Exception, ex.Message, ex.ToString()); + } + + incomingDataList.Add(incomingData); + + } + return incomingDataList; + } + private IncomingFromExternal BuildIncomingFromExternal(spriceout SalePrice) + { + var incomingData = new IncomingFromExternal() + { + + DataType = EnumIncomingDataType.SalePrice.ToString(), + DataAction = EnumExchangeDataAction.Add, + SourceSystem = EnumSystemType.ERP.ToString(), + SourceDataId = SalePrice.spriceout_part, + SourceDataGroupCode = SalePrice.spriceout_part, + SourceDataDetailCode = SalePrice.spriceout_cust, + SourceDataContent = JsonSerializer.Serialize(SalePrice), + WriteTime = DateTime.Now, + Writer = nameof(TyrpIncomingBackgroundWorker), + DestinationSystem = EnumSystemType.ERP.ToString(), + }; + return incomingData; + } + + private static SalePriceExchangeDto BuildScrapNoteOrderExchangeMes(spriceout SalePrice) + { + + var price = new SalePriceExchangeDto() + { + ItemCode = SalePrice.spriceout_part, + CustomerCode = SalePrice.spriceout_cust, + SalePrice = SalePrice.spriceout_price, + Description = "接口同步", + }; + return price; + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/StdCostPriceConverter.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/StdCostPriceConverter.cs new file mode 100644 index 000000000..881c3c830 --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/StdCostPriceConverter.cs @@ -0,0 +1,75 @@ +using System.Collections.Generic; +using System.Linq; +using System.Text.Json; +using System.Threading.Tasks; +using Microsoft.Extensions.Logging; +using Volo.Abp.Guids; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Wms.DataExchange.Domain; +using Win_in.Sfs.Wms.DataExchange.WMS.StdCostPrice; + +namespace Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent.Incoming; + +public class StdCostPriceConverter : IIncomingConverter +{ + private readonly IIncomingToWmsManager _incomingToWmsManager; + private readonly IObjectMapper _objectMapper; + private readonly ILogger _logger; + private readonly IGuidGenerator _guidGenerator; + private readonly IIncomingFromExternalManager _incomingFromExternalManager; + + public StdCostPriceConverter( + IIncomingToWmsManager incomingToWmsManager, + IObjectMapper objectMapper, + ILogger logger, + IGuidGenerator guidGenerator +, + IIncomingFromExternalManager incomingFromExternalManager + +) + { + _incomingToWmsManager = incomingToWmsManager; + _objectMapper = objectMapper; + _logger = logger; + _guidGenerator = guidGenerator; + _incomingFromExternalManager = incomingFromExternalManager; + } + public virtual async Task ConvertAsync(List incomingFromExternalList) + { + if (!incomingFromExternalList.Any()) + { + _logger.LogInformation("无标准成本价格转换"); + return; + } + var incomingToWmsDataList = await BuildIncomingToWmsOfPurchaseOrderAsync(incomingFromExternalList).ConfigureAwait(false); + await _incomingToWmsManager.CreateBulkAsync(incomingToWmsDataList).ConfigureAwait(false); + //归档 + await _incomingFromExternalManager.ArchiveManyAsync(incomingFromExternalList).ConfigureAwait(false); + + } + private async Task> BuildIncomingToWmsOfPurchaseOrderAsync(List incomingDataList) + { + await Task.CompletedTask.ConfigureAwait(false); + var incomingToWmsList = new List(); + var groups = incomingDataList.GroupBy(p => p.SourceDataGroupCode); + foreach (var group in groups) + { + var first = group.First(); + var incomingToWms = new IncomingToWms() + { + DataType = first.DataType, + DataAction = first.DataAction, + SourceSystem = first.SourceSystem, + DataIdentityCode = first.SourceDataGroupCode, + }; + incomingToWms.SetId(_guidGenerator.Create()); + incomingToWms.SetEffectiveDate(first.EffectiveDate); + var exchangeStdCostPrice = JsonSerializer.Deserialize(first.DestinationDataContent); + var wmsStdCostPrice = _objectMapper.Map(exchangeStdCostPrice); + incomingToWms.DataContent = JsonSerializer.Serialize(wmsStdCostPrice); + incomingToWmsList.Add(incomingToWms); + } + return incomingToWmsList; + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/StdCostPriceReader.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/StdCostPriceReader.cs new file mode 100644 index 000000000..fe6a5dafb --- /dev/null +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/StdCostPriceReader.cs @@ -0,0 +1,131 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text.Json; +using System.Threading.Tasks; +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.Logging; +using Volo.Abp.Guids; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Wms.DataExchange.Domain; +using Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; +using Win_in.Sfs.Wms.DataExchange.Domain.Shared; +using Win_in.Sfs.Wms.DataExchange.WMS.StdCostPrice; + +namespace Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent.Incoming; +public class StdCostPriceReader : IReader +{ + private readonly IProductManager _productManager; + private readonly IIncomingFromExternalManager _incomingFromExternalManager; + private readonly ILogger _logger; + private readonly IGuidGenerator _guidGenerator; + private readonly IConfiguration _configuration; + private readonly IStdCostPriceSheetAppService _StdCostPriceAppService; + private readonly IObjectMapper _objectMapper; + public StdCostPriceReader( + IProductManager productManager + , IIncomingFromExternalManager incomingFromExternalManager + , IGuidGenerator guidGenerator + , ILogger logger + , IConfiguration configuration, + IStdCostPriceSheetAppService StdCostPriceSheetAppService, + IObjectMapper objectMapper + ) + { + _guidGenerator = guidGenerator; + _configuration = configuration; + _productManager = productManager; + _incomingFromExternalManager = incomingFromExternalManager; + _logger = logger; + _StdCostPriceAppService = StdCostPriceSheetAppService; + _objectMapper = objectMapper; + } + + public virtual async Task> ReadAsync() + { + //从ERP读取待处理part + var toBeProcessedProducts = await _productManager.GetToBeProcessedListAsync().ConfigureAwait(false); + if (!toBeProcessedProducts.Any()) + { + _logger.LogInformation("no StdCostPrices"); + return new List(); + } + //获取wms标准成本单价数据 + SfsBaseDataRequestInputBase input = new SfsBaseDataRequestInputBase(); + var wmsStdCostPrices = await _StdCostPriceAppService.GetAllListByFilterAsync(input).ConfigureAwait(false); + var wmsToStdCostPriceExchangeDtos = _objectMapper.Map, List>(wmsStdCostPrices); + List eosToBomExchangeDtos = new List(); + foreach (var toBeProcessedProduct in toBeProcessedProducts) + { + var StdCostPrice = BuildScrapNoteOrderExchangeMes(toBeProcessedProduct); + eosToBomExchangeDtos.Add(StdCostPrice); + } + //和wms和eos数据进行比较,获取需要处理得数据 + var updateDatas = eosToBomExchangeDtos.Except(wmsToStdCostPriceExchangeDtos).ToList(); + if (!updateDatas.Any()) + { + _logger.LogInformation("no StdCostPrices"); + return new List(); + } + //StdCostPrice逐一转换为StdCostPrice + var incomingDataList = BuildIncomingFromExternalFromBomAsync(updateDatas, toBeProcessedProducts); + await _incomingFromExternalManager.CreateBulkAsync(incomingDataList).ConfigureAwait(false); + return incomingDataList; + } + private List BuildIncomingFromExternalFromBomAsync(List updateDatas, List toBeProcessedProducts) + { + var incomingDataList = new List(); + foreach (var data in updateDatas) + { + var item = toBeProcessedProducts.FirstOrDefault(r => r.mes_product_part == data.ItemCode); + var incomingData = BuildIncomingFromExternal(item); + + incomingData.SetEffectiveDate(DateTime.Now); + + try + { + incomingData.DestinationDataContent = JsonSerializer.Serialize(data); + incomingData.SetId(_guidGenerator.Create()); + } + catch (Exception ex) + { + incomingData.SetError(EnumExchangeDataErrorCode.Exception, ex.Message, ex.ToString()); + } + + incomingDataList.Add(incomingData); + + } + return incomingDataList; + } + private IncomingFromExternal BuildIncomingFromExternal(mes_product product) + { + var incomingData = new IncomingFromExternal() + { + + DataType = EnumIncomingDataType.StdCostPrice.ToString(), + DataAction = EnumExchangeDataAction.Add, + SourceSystem = EnumSystemType.ERP.ToString(), + SourceDataId = product.mes_product_part_ser.ToString(), + SourceDataGroupCode = product.mes_product_part, + SourceDataDetailCode = product.mes_product_part, + SourceDataContent = JsonSerializer.Serialize(product), + WriteTime = DateTime.Now, + Writer = nameof(TyrpIncomingBackgroundWorker), + DestinationSystem = EnumSystemType.ERP.ToString(), + }; + return incomingData; + } + + private static StdCostPriceExchangeDto BuildScrapNoteOrderExchangeMes(mes_product product) + { + + var price = new StdCostPriceExchangeDto() + { + ItemCode = product.mes_product_part, + StdCostPrice = product.mes_product_price_std, + Description = "接口同步", + }; + return price; + } +} diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/TyrpIncomingBackgroundWorker.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/TyrpIncomingBackgroundWorker.cs index 81dc7c649..2578ee3a5 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/TyrpIncomingBackgroundWorker.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Incoming/TyrpIncomingBackgroundWorker.cs @@ -126,6 +126,30 @@ public class TyrpIncomingBackgroundWorker : AsyncPeriodicBackgroundWorkerBase var customersFromExternalList = await CustomerReader.ReadAsync().ConfigureAwait(false); //转换Customer await CustomerConverter.ConvertAsync(customersFromExternalList).ConfigureAwait(false); + + Logger.LogInformation($"Read PurchasePrice");//采购价格 + var PurchasePriceReader = workerContext.ServiceProvider.GetRequiredService(); + var PurchasePriceConverter = workerContext.ServiceProvider.GetRequiredService(); + //读取并保存PurchasePrice + var purchasePriceFromExternalList = await PurchasePriceReader.ReadAsync().ConfigureAwait(false); + //转换PurchasePrice + await PurchasePriceConverter.ConvertAsync(purchasePriceFromExternalList).ConfigureAwait(false); + + Logger.LogInformation($"Read SalePrice");//销售价格 + var SalePriceReader = workerContext.ServiceProvider.GetRequiredService(); + var SalePriceConverter = workerContext.ServiceProvider.GetRequiredService(); + //读取并保存SalePrice + var salePriceFromExternalList = await SalePriceReader.ReadAsync().ConfigureAwait(false); + //转换SalePrice + await SalePriceConverter.ConvertAsync(salePriceFromExternalList).ConfigureAwait(false); + + Logger.LogInformation($"Read StdCostPrice");//标准成本价格 + var StdCostPriceReader = workerContext.ServiceProvider.GetRequiredService(); + var StdCostPriceConverter = workerContext.ServiceProvider.GetRequiredService(); + //读取并保存StdCostPrice + var stdCostPriceFromExternalList = await StdCostPriceReader.ReadAsync().ConfigureAwait(false); + //转换StdCostPrice + await StdCostPriceConverter.ConvertAsync(stdCostPriceFromExternalList).ConfigureAwait(false); } else { diff --git a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Outgoing/DeliverNoteConverter.cs b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Outgoing/DeliverNoteConverter.cs index 7cc307439..a8d5409e5 100644 --- a/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Outgoing/DeliverNoteConverter.cs +++ b/be/DataExchange/Fawtyg/Win_in.Sfs.Wms.DataExchange.Fawtyg.TyrpAgent/Outgoing/DeliverNoteConverter.cs @@ -4,6 +4,7 @@ using System.Linq; using System.Text.Json; using System.Threading.Tasks; using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Application.Contracts; using Win_in.Sfs.Wms.DataExchange.Domain; using Win_in.Sfs.Wms.DataExchange.Domain.Fawtyg.Tyrp; using Win_in.Sfs.Wms.DataExchange.Domain.Shared; @@ -19,16 +20,19 @@ public class DeliverNoteConverter : IOutgoingConverter private readonly IOutgoingToExternalManager _outgoingToExternalManager; // private readonly IUserDepartmentAppService _departmentAppService; private readonly IObjectMapper _objectMapper; + private readonly ISalePriceSheetAppService _salePriceSheetAppService; public DeliverNoteConverter( IOutgoingFromWmsManager outgoingFromWmsManager , IOutgoingToExternalManager outgoingToExternalManager - , IObjectMapper objectMapper + , IObjectMapper objectMapper, + ISalePriceSheetAppService salePriceSheetAppService ) { _outgoingFromWmsManager = outgoingFromWmsManager; _outgoingToExternalManager = outgoingToExternalManager; _objectMapper = objectMapper; + _salePriceSheetAppService = salePriceSheetAppService; } /// @@ -40,38 +44,22 @@ public class DeliverNoteConverter : IOutgoingConverter var outgoingToExternalList = new List(); //获取要同步得数据 var outgoingFromWmsList = await _outgoingFromWmsManager.GetToBeProcessedListAsync(EnumOutgoingDataType.Deliver, EnumSystemType.ERP).ConfigureAwait(false); + List outgoingFromWmsToTyrp = new List();//待传列表 foreach (var outgoingFromWms in outgoingFromWmsList) { - string tyrpNumber = outgoingFromWms.TyrpNumber; - #region 主表 + bool flag = true;//用于标注是否同步,如果没有销售价格不同步 + string tyrpNumber = outgoingFromWms.TyrpNumber; var wmsReceipt = JsonSerializer.Deserialize(outgoingFromWms.DataContent); - var exchangeReceipt = _objectMapper.Map(wmsReceipt); - var purchaseOrder = BuildDataInterface(exchangeReceipt, tyrpNumber); - var outgoingToExternal = new OutgoingToExternal() - { - DataType = EnumOutgoingDataType.Deliver.ToString(), - TableType = EnumExchangeTableType.MainTable, - DataAction = outgoingFromWms.DataAction, - SerialNumber=tyrpNumber, - SourceSystem = EnumSystemType.WMS.ToString(), - SourceDataId = wmsReceipt.Id.ToString(), - SourceDataGroupCode = wmsReceipt.Number, - SourceDataDetailCode = wmsReceipt.Number, - Writer = nameof(TyrpOutgoingBackgroundWorker), - DestinationSystem = EnumSystemType.ERP.ToString(), - DestinationDataId = "", - }; - outgoingToExternal.SetEffectiveDate(outgoingFromWms.EffectiveDate); - outgoingToExternal.SourceDataContent = JsonSerializer.Serialize(exchangeReceipt); - outgoingToExternal.DestinationDataContent = JsonSerializer.Serialize(purchaseOrder); - outgoingToExternalList.Add(outgoingToExternal); - #endregion - #region 明细 - var WipDetails = wmsReceipt.Details.GroupBy(r=>new { r.Number,r.ItemCode,r.FromLocationErpCode}).Select(p => new DeliverNoteDetailExchangeDto { Qty = p.Sum(itm => itm.Qty), Number = p.Key.Number, ItemCode = p.Key.ItemCode, FromLocationErpCode = p.Key.FromLocationErpCode }); - + var WipDetails = wmsReceipt.Details.GroupBy(r => new { r.Number, r.ItemCode, r.FromLocationErpCode }).Select(p => new DeliverNoteDetailExchangeDto { Qty = p.Sum(itm => itm.Qty), Number = p.Key.Number, ItemCode = p.Key.ItemCode, FromLocationErpCode = p.Key.FromLocationErpCode }); foreach (var detail in WipDetails) { + var item= _salePriceSheetAppService.GetByItemCodeAndCustomerCode(detail.ItemCode, wmsReceipt.CustomerCode); + if (item==null) + { + flag = false; + continue; + } var outgoingDetailToExternal = new OutgoingToExternal() { DataType = EnumOutgoingDataType.Deliver.ToString(), @@ -93,11 +81,38 @@ public class DeliverNoteConverter : IOutgoingConverter outgoingToExternalList.Add(outgoingDetailToExternal); } #endregion + #region 主表 + if (flag) + { + var exchangeReceipt = _objectMapper.Map(wmsReceipt); + var purchaseOrder = BuildDataInterface(exchangeReceipt, tyrpNumber); + var outgoingToExternal = new OutgoingToExternal() + { + DataType = EnumOutgoingDataType.Deliver.ToString(), + TableType = EnumExchangeTableType.MainTable, + DataAction = outgoingFromWms.DataAction, + SerialNumber = tyrpNumber, + SourceSystem = EnumSystemType.WMS.ToString(), + SourceDataId = wmsReceipt.Id.ToString(), + SourceDataGroupCode = wmsReceipt.Number, + SourceDataDetailCode = wmsReceipt.Number, + Writer = nameof(TyrpOutgoingBackgroundWorker), + DestinationSystem = EnumSystemType.ERP.ToString(), + DestinationDataId = "", + }; + outgoingToExternal.SetEffectiveDate(outgoingFromWms.EffectiveDate); + outgoingToExternal.SourceDataContent = JsonSerializer.Serialize(exchangeReceipt); + outgoingToExternal.DestinationDataContent = JsonSerializer.Serialize(purchaseOrder); + outgoingToExternalList.Add(outgoingToExternal); + outgoingFromWmsToTyrp.Add(outgoingFromWms);//加入到待传列表 + } + #endregion + } //插入到中间表OutgoingToExternal await _outgoingToExternalManager.CreateManyAsync(outgoingToExternalList).ConfigureAwait(false); //将outgoingFromWms数据归档 - await _outgoingFromWmsManager.ArchiveManyAsync(outgoingFromWmsList).ConfigureAwait(false); + await _outgoingFromWmsManager.ArchiveManyAsync(outgoingFromWmsToTyrp).ConfigureAwait(false); return outgoingToExternalList; } diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/AgentModule.cs b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/AgentModule.cs index 31b6599f3..28aa02cc5 100644 --- a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/AgentModule.cs +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/AgentModule.cs @@ -49,15 +49,15 @@ public class AgentModule : AbpModule PreConfigure(options => { //Polly 重试3次 - options.ProxyClientBuildActions.Add((remoteServiceName, clientBuilder) => - { - clientBuilder.AddTransientHttpErrorPolicy(policyBuilder => - policyBuilder.WaitAndRetryAsync( - 3, - i => TimeSpan.FromSeconds(Math.Pow(2, i)) - ) - ); - }); + //options.ProxyClientBuildActions.Add((remoteServiceName, clientBuilder) => + //{ + // clientBuilder.AddTransientHttpErrorPolicy(policyBuilder => + // policyBuilder.WaitAndRetryAsync( + // 3, + // i => TimeSpan.FromSeconds(Math.Pow(2, i)) + // ) + // ); + //}); //默认添加Authorization Header: Bearer Token options.ProxyClientActions.Add((a, s, h) => diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/IncomingToWmsExtensions.cs b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/IncomingToWmsExtensions.cs index f68a7724f..9e2224360 100644 --- a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/IncomingToWmsExtensions.cs +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/IncomingToWmsExtensions.cs @@ -21,7 +21,7 @@ public static class IncomingToWmsExtensions { var purchaseOrder = JsonSerializer.Deserialize(incomingConverted.DataContent); var purchaseOrderAppService = workerContext.ServiceProvider.GetRequiredService(); - await purchaseOrderAppService.CreateAsync(purchaseOrder).ConfigureAwait(false); + await purchaseOrderAppService.CreateOrUpdateAsync(purchaseOrder).ConfigureAwait(false); } public static async Task HandleAsnsAsync(this IncomingToWms incomingConverted, PeriodicBackgroundWorkerContext workerContext) @@ -126,7 +126,24 @@ public static class IncomingToWmsExtensions var customerAppService = workerContext.ServiceProvider.GetRequiredService(); await customerAppService.UpsertAsyncByInterface(customer).ConfigureAwait(false); } - + public static async Task HandlePurchasePricesAsync(this IncomingToWms incomingConverted, PeriodicBackgroundWorkerContext workerContext) + { + var purchaseprice = JsonSerializer.Deserialize(incomingConverted.DataContent); + var purchasepriceAppService = workerContext.ServiceProvider.GetRequiredService(); + await purchasepriceAppService.UpsertAsyncByInterface(purchaseprice).ConfigureAwait(false); + } + public static async Task HandleSalePricesAsync(this IncomingToWms incomingConverted, PeriodicBackgroundWorkerContext workerContext) + { + var saleprice = JsonSerializer.Deserialize(incomingConverted.DataContent); + var salepriceAppService = workerContext.ServiceProvider.GetRequiredService(); + await salepriceAppService.UpsertAsyncByInterface(saleprice).ConfigureAwait(false); + } + public static async Task HandleStdCostPricesAsync(this IncomingToWms incomingConverted, PeriodicBackgroundWorkerContext workerContext) + { + var stdcostprice = JsonSerializer.Deserialize(incomingConverted.DataContent); + var stdcostpriceAppService = workerContext.ServiceProvider.GetRequiredService(); + await stdcostpriceAppService.UpsertAsyncByInterface(stdcostprice).ConfigureAwait(false); + } public static async Task HandleCustomerItemsAsync(this IncomingToWms incomingConverted, PeriodicBackgroundWorkerContext workerContext) { var customerItem = JsonSerializer.Deserialize(incomingConverted.DataContent); diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/IncomingToWmsWorker.cs b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/IncomingToWmsWorker.cs index 02899143f..e152404a9 100644 --- a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/IncomingToWmsWorker.cs +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/IncomingToWmsWorker.cs @@ -62,7 +62,7 @@ public class IncomingToWmsWorker : AsyncPeriodicBackgroundWorkerBase } private async Task HandleIncomingDataAsync(PeriodicBackgroundWorkerContext workerContext) - { + { //Resolve dependencies var incomingToWmsManager = workerContext.ServiceProvider.GetRequiredService(); //Do the work @@ -71,9 +71,9 @@ public class IncomingToWmsWorker : AsyncPeriodicBackgroundWorkerBase foreach (var incomingToWms in incomingToWmsList) { try - { - await AddOrUpdateWmsAsync(workerContext, incomingToWms).ConfigureAwait(false); - + { + await AddOrUpdateWmsAsync(workerContext, incomingToWms).ConfigureAwait(false); + } catch (AbpValidationException ex) { @@ -141,6 +141,15 @@ public class IncomingToWmsWorker : AsyncPeriodicBackgroundWorkerBase case EnumIncomingDataType.Customer: await incomingToWms.HandleCustomersAsync(workerContext).ConfigureAwait(false); break; + case EnumIncomingDataType.PurchasePrice: + await incomingToWms.HandlePurchasePricesAsync(workerContext).ConfigureAwait(false); + break; + case EnumIncomingDataType.SalePrice: + await incomingToWms.HandleSalePricesAsync(workerContext).ConfigureAwait(false); + break; + case EnumIncomingDataType.StdCostPrice: + await incomingToWms.HandleStdCostPricesAsync(workerContext).ConfigureAwait(false); + break; case EnumIncomingDataType.CustomerItem: await incomingToWms.HandleCustomerItemsAsync(workerContext).ConfigureAwait(false); break; @@ -172,23 +181,23 @@ public class IncomingToWmsWorker : AsyncPeriodicBackgroundWorkerBase await incomingToWms.HandleInventoryLabelsAsync(workerContext).ConfigureAwait(false); break; case EnumIncomingDataType.BackFlush: - // await incomingToWms.HandleBackFlushsAsync(workerContext).ConfigureAwait(false); + // await incomingToWms.HandleBackFlushsAsync(workerContext).ConfigureAwait(false); await SendBackFlush(workerContext, incomingToWms).ConfigureAwait(false); break; case EnumIncomingDataType.None: default: throw new ArgumentOutOfRangeException(); } - if( incomingToWms.Status != EnumExchangeDataStatus.Error) + if (incomingToWms.Status != EnumExchangeDataStatus.Error) { incomingToWms.SetSuccess(); - } + } } private async Task SendBackFlush(PeriodicBackgroundWorkerContext workerContext, IncomingToWms incomingToWms) { // 定义请求的 URL // string apiUrl = "http://10.164.113.31:60085/api/wms/store/product-receipt-note"; - string apiUrl = _options.Value.IncomingOptions.apiUrl+ "api/wms/store/backFlush-note/create-many"; + string apiUrl = _options.Value.IncomingOptions.apiUrl + "api/wms/store/backFlush-note/create-many"; if (!string.IsNullOrEmpty(_options.Value.IncomingOptions.apiUrl)) { @@ -237,6 +246,8 @@ public class IncomingToWmsWorker : AsyncPeriodicBackgroundWorkerBase if (!string.IsNullOrEmpty(_options.Value.IncomingOptions.apiUrl)) { var productReceiptJson = JsonSerializer.Deserialize(incomingToWms.DataContent); + var memos = productReceiptJson.Details.Select(r => r.Remark).ToList(); + string memostr = String.Join(", ", memos); productReceiptJson.Worker = "Mes"; try { @@ -256,6 +267,7 @@ public class IncomingToWmsWorker : AsyncPeriodicBackgroundWorkerBase // 读取响应内容并返回 string responseBody = await response.Content.ReadAsStringAsync().ConfigureAwait(false); + Logger.LogInformation("标签" + memostr); } catch (HttpRequestException ex) { @@ -274,10 +286,10 @@ public class IncomingToWmsWorker : AsyncPeriodicBackgroundWorkerBase //{ // //Resolve dependencies // var incomingToWmsManager = workerContext.ServiceProvider.GetRequiredService(); - + // //归档并删除 // await incomingToWmsManager.ArchiveAutoSaveAsync(incomingToWms).ConfigureAwait(false); - + //} } diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/appsettings.json b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/appsettings.json index 3ff6fe613..156e965e2 100644 --- a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/appsettings.json +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Agent/appsettings.json @@ -42,14 +42,14 @@ "IncomingOptions": { "Active": true, "PeriodSeconds": 10, - "RetryTimes": 3, + "RetryTimes": 1, "BatchSize": 100, "apiUrl": "http://10.164.113.31:60085/" }, "OutgoingOptions": { "Active": false, "PeriodSeconds": 10, - "RetryTimes": 3, + "RetryTimes": 1, "BatchSize": 100, "BaseUrl": "https://localhost:7034/test", "Username": "username", diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/ProductReceiptNote/ProductReceiptNoteSumDetailExchangeDto.cs b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/ProductReceiptNote/ProductReceiptNoteSumDetailExchangeDto.cs new file mode 100644 index 000000000..d9a1e8cc4 --- /dev/null +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/ProductReceiptNote/ProductReceiptNoteSumDetailExchangeDto.cs @@ -0,0 +1,52 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Xml.Linq; + +namespace Win_in.Sfs.Wms.DataExchange.WMS.ProductReceiptNote; +public class ProductReceiptNoteSumDetailExchangeDto +{ + /// + /// 零件编号 + /// + [Display(Name = "零件编号")] + public string itemCode { get; set; } + /// + /// 库位编码 + /// + [Display(Name = "零件编号")] + public string locationCode { get; set; } + + /// + /// MesGuid + /// + [Display(Name = "MesGuid")] + public string MesGuid { get; set; } + + /// + /// id + /// + [Display(Name = "id")] + public string Memo { get; set; } + + /// + /// 生效日期 + /// + [Display(Name = "生效日期")] + public DateTime CreatDate { get; set; } = DateTime.Now.Date; + + /// + /// 数量 + /// + [Display(Name = "数量")] + public decimal Qty { get; set; } + /// + /// 返喷数量 + /// + [Display(Name = "返喷数量")] + public decimal BadQty { get; set; } + +} diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/PurchasePrice/PurchasePriceExchangeDto.cs b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/PurchasePrice/PurchasePriceExchangeDto.cs new file mode 100644 index 000000000..423d484e2 --- /dev/null +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/PurchasePrice/PurchasePriceExchangeDto.cs @@ -0,0 +1,49 @@ +using System.ComponentModel; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Wms.DataExchange.WMS.Bom; + +namespace Win_in.Sfs.Wms.DataExchange.WMS.PurchasePrice; +public class PurchasePriceExchangeDto +{ + /// + /// 物品代码 + /// + + [Display(Name = "物品代码")] + [Required] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemCode { get; set; } + + /// + /// 供应商编号 + /// + [Display(Name = "供应商编号")] + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string SupplierCode { get; set; } + + /// + /// 价格单描述 + /// + public string Description { get; set; } + + /// + /// 客户简称 + /// + public decimal PurchasePrice { get; set; } + + public override bool Equals(object obj) + { + if (obj is PurchasePriceExchangeDto) + { + PurchasePriceExchangeDto purchaseprice = obj as PurchasePriceExchangeDto; + return ItemCode == purchaseprice.ItemCode && SupplierCode == purchaseprice.SupplierCode && PurchasePrice == purchaseprice.PurchasePrice; + } + return false; + } + public override int GetHashCode() + { + return ItemCode.GetHashCode() ^ SupplierCode.GetHashCode() ^ PurchasePrice.GetHashCode(); + } +} diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/SalePrice/SalePriceExchangeDto.cs b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/SalePrice/SalePriceExchangeDto.cs new file mode 100644 index 000000000..b422a5408 --- /dev/null +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/SalePrice/SalePriceExchangeDto.cs @@ -0,0 +1,55 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using IdentityServer4.Models; +using System.Xml.Linq; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Wms.DataExchange.WMS.SalePrice; + +public class SalePriceExchangeDto +{ + /// + /// 物品代码 + /// + + [Display(Name = "物品代码")] + [Required] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemCode { get; set; } + + /// + /// 客户编号 + /// + [Display(Name = "客户编号")] + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string CustomerCode { get; set; } + + /// + /// 价格单描述 + /// + public string Description { get; set; } + + /// + /// 销售价格 + /// + public decimal SalePrice { get; set; } + + public override bool Equals(object obj) + { + if (obj is SalePriceExchangeDto) + { + SalePriceExchangeDto saleprice = obj as SalePriceExchangeDto; + return ItemCode == saleprice.ItemCode && CustomerCode == saleprice.CustomerCode && SalePrice == saleprice.SalePrice; + } + return false; + } + public override int GetHashCode() + { + return ItemCode.GetHashCode() ^ CustomerCode.GetHashCode() ^ SalePrice.GetHashCode(); + } +} diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/StdCostPrice/StdCostPriceExchangeDto.cs b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/StdCostPrice/StdCostPriceExchangeDto.cs new file mode 100644 index 000000000..72024e249 --- /dev/null +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/WMS/StdCostPrice/StdCostPriceExchangeDto.cs @@ -0,0 +1,45 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using IdentityServer4.Models; +using System.Xml.Linq; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Wms.DataExchange.WMS.StdCostPrice; +public class StdCostPriceExchangeDto +{ + /// + /// 物品代码 + /// + + [Display(Name = "物品代码")] + [Required] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemCode { get; set; } + /// + /// 价格单描述 + /// + public string Description { get; set; } + + /// + /// 标准成本价 + /// + public decimal StdCostPrice { get; set; } + + public override bool Equals(object obj) + { + if (obj is StdCostPriceExchangeDto) + { + StdCostPriceExchangeDto scp = obj as StdCostPriceExchangeDto; + return ItemCode == scp.ItemCode && StdCostPrice == scp.StdCostPrice; + } + return false; + } + public override int GetHashCode() + { + return ItemCode.GetHashCode() ^ StdCostPrice.GetHashCode(); + } +} diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/Win_in.Sfs.Wms.DataExchange.Application.Contracts.xml b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/Win_in.Sfs.Wms.DataExchange.Application.Contracts.xml index 01d68a873..fdd8322ca 100644 --- a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/Win_in.Sfs.Wms.DataExchange.Application.Contracts.xml +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Application.Contracts/Win_in.Sfs.Wms.DataExchange.Application.Contracts.xml @@ -841,6 +841,41 @@ 明细列表 + + + 零件编号 + + + + + 库位编码 + + + + + MesGuid + + + + + id + + + + + 生效日期 + + + + + 数量 + + + + + 返喷数量 + + 产成品物料号 @@ -991,6 +1026,26 @@ 明细 + + + 物品代码 + + + + + 供应商编号 + + + + + 价格单描述 + + + + + 客户简称 + + 库位组 @@ -1256,6 +1311,26 @@ 生效日期 + + + 物品代码 + + + + + 客户编号 + + + + + 价格单描述 + + + + + 销售价格 + + 目标箱码 @@ -1356,6 +1431,21 @@ 明细 + + + 物品代码 + + + + + 价格单描述 + + + + + 标准成本价 + + ASN单号 diff --git a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Domain.Shared/Enums/EnumIncomingDataType.cs b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Domain.Shared/Enums/EnumIncomingDataType.cs index 5d89c1c37..9f0e609e4 100644 --- a/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Domain.Shared/Enums/EnumIncomingDataType.cs +++ b/be/DataExchange/src/Win_in.Sfs.Wms.DataExchange.Domain.Shared/Enums/EnumIncomingDataType.cs @@ -98,5 +98,17 @@ public enum EnumIncomingDataType /// 退货单 /// PurchaseReturn = 23, + /// + /// 采购价格 + /// + PurchasePrice=24, + /// + /// 销售价格 + /// + SalePrice = 25, + /// + /// 标准成本价格 + /// + StdCostPrice=26, } diff --git a/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/Properties/PublishProfiles/FolderProfile.pubxml b/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/Properties/PublishProfiles/FolderProfile.pubxml index 4adc13526..39db2b9e4 100644 --- a/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/Properties/PublishProfiles/FolderProfile.pubxml +++ b/be/Hosts/Basedata.Host/Win_in.Sfs.Basedata.HttpApi.Host/Properties/PublishProfiles/FolderProfile.pubxml @@ -4,17 +4,17 @@ https://go.microsoft.com/fwlink/?LinkID=208121. --> - true + false false true Release Any CPU FileSystem - .\..\..\..\OutPut\BaseData\ + D:\发布\WMS\base FileSystem net6.0 6184eab9-b44b-42fc-8cd3-e36933a3dad5 false - + \ No newline at end of file diff --git a/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/Properties/PublishProfiles/FolderProfile.pubxml b/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/Properties/PublishProfiles/FolderProfile.pubxml index 83d3b93a7..47bf33bb7 100644 --- a/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/Properties/PublishProfiles/FolderProfile.pubxml +++ b/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/Properties/PublishProfiles/FolderProfile.pubxml @@ -4,17 +4,17 @@ https://go.microsoft.com/fwlink/?LinkID=208121. --> - true + false false true Release Any CPU FileSystem - .\..\..\..\OutPut\StoreHost\ + D:\发布\WMS\store FileSystem net6.0 488eeada-cfed-4016-9884-7a1dcbe5eb9c false - + \ No newline at end of file diff --git a/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/Properties/PublishProfiles/FolderProfile1.pubxml b/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/Properties/PublishProfiles/FolderProfile1.pubxml deleted file mode 100644 index c238ca481..000000000 --- a/be/Hosts/Wms.Host/Win_in.Sfs.Wms.Store.HttpApi.Host/Properties/PublishProfiles/FolderProfile1.pubxml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - False - False - True - Release - Any CPU - FileSystem - D:\~all-publish\WMS2.0_东阳\Win_in.Sfs.Wms.Store.HttpApi.Host - FileSystem - - \ No newline at end of file diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/EquipmentController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/EquipmentController.cs new file mode 100644 index 000000000..cff5f59f1 --- /dev/null +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/EquipmentController.cs @@ -0,0 +1,64 @@ +using System; +using System.Collections.Generic; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Microsoft.Extensions.Options; +using Volo.Abp.AspNetCore.Mvc; +using Volo.Abp.Json; +using Win_in.Sfs.Basedata.Application.Contracts; + +namespace Win_in.Sfs.Wms.Pda.Controllers.BaseDatas; + +/// +/// 器具控制器 +/// +[ApiController] +[Route($"{PdaHostConst.ROOT_ROUTE}Equipment")] +public class EquipmentController : AbpController +{ + private readonly IEquipmentAppService _dictApp; + private readonly IEquipmentLocAppService _locApp; + + /// + /// + /// + /// + public EquipmentController(IEquipmentAppService dictApp, + + + IEquipmentLocAppService locApp, + + IOptions options) + { + _locApp = locApp; + _dictApp = dictApp; + var str = options.Value.DefaultDateTimeFormat; + Console.WriteLine(str); + } + + /// + /// 按代码获取字典 + /// + /// 字典代码 + /// + [HttpGet("by-code")] + public virtual async Task GetByCodeAsync(string code) + { + var dtos = await _dictApp.GetByCodeAsync(code).ConfigureAwait(false); + + return dtos; + } + [HttpGet("getLocs")] + + + public virtual async Task> GetLocsAsync() + { + var dtos = await _locApp.GetLocsAsync().ConfigureAwait(false); + + return dtos; + } + + + + +} diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/KittingController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/KittingController.cs new file mode 100644 index 000000000..f2f15ec47 --- /dev/null +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/KittingController.cs @@ -0,0 +1,43 @@ +using System; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Microsoft.Extensions.Options; +using Volo.Abp.AspNetCore.Mvc; +using Volo.Abp.Json; +using Win_in.Sfs.Basedata.Application.Contracts; + +namespace Win_in.Sfs.Wms.Pda.Controllers.BaseDatas; + +/// +/// 器具控制器 +/// +[ApiController] +[Route($"{PdaHostConst.ROOT_ROUTE}Kitting")] +public class KittingController : AbpController +{ + private readonly IKittingAppService _dictApp; + + /// + /// + /// + /// + public KittingController(IKittingAppService dictApp,IOptions options) + { + _dictApp = dictApp; + var str = options.Value.DefaultDateTimeFormat; + Console.WriteLine(str); + } + + /// + /// 按代码获取字典 + /// + /// 字典代码 + /// + [HttpGet("by-code")] + public virtual async Task GetByCodeAsync(string code) + { + var dtos = await _dictApp.GetByCodeAsync(code).ConfigureAwait(false); + + return dtos; + } +} diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/PositionCodeController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/PositionCodeController.cs new file mode 100644 index 000000000..cd5f72c23 --- /dev/null +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/PositionCodeController.cs @@ -0,0 +1,40 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp.AspNetCore.Mvc; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Pda.Controllers.BaseDatas; + +/// +/// +/// +[ApiController] +[Route($"{PdaHostConst.ROOT_ROUTE}position-code")] +public class PositionCodeController : AbpController +{ + private readonly IPositionCodeAppService _positionCodeAppService; + + /// + /// + /// + /// + public PositionCodeController(IPositionCodeAppService positionCodeAppService) + { + _positionCodeAppService = positionCodeAppService; + } + + /// + /// 根据code获取库位信息 + /// + /// + /// + [HttpGet("{code}")] + public virtual async Task GetAsync(string code) + { + var result = await _positionCodeAppService.GetByCodeAsync(code).ConfigureAwait(false); + return result; + } + +} diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/SplitPackingRecController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/SplitPackingRecController.cs new file mode 100644 index 000000000..b95eb57c5 --- /dev/null +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/BaseDatas/SplitPackingRecController.cs @@ -0,0 +1,42 @@ +using System; +using System.Collections.Generic; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Microsoft.Extensions.Options; +using Volo.Abp.AspNetCore.Mvc; +using Volo.Abp.Json; +using Win_in.Sfs.Basedata.Application.Contracts; + +namespace Win_in.Sfs.Wms.Pda.Controllers.BaseDatas; + +/// +/// 字典控制器 +/// +[ApiController] +[Route($"{PdaHostConst.ROOT_ROUTE}split-packing-rec")] +public class SplitPackingRecController : AbpController +{ + private readonly ISplitPackingRecAppService _splitPackingRecApp; + + /// + /// + /// + /// + public SplitPackingRecController(ISplitPackingRecAppService splitPackingRecApp, IOptions options) + { + _splitPackingRecApp = splitPackingRecApp; + var str = options.Value.DefaultDateTimeFormat; + Console.WriteLine(str); + } + + /// + /// 取拆分记录列表 + /// + /// + /// + [HttpPost("get-all")] + public virtual async Task> GetAllListByFilterAsync(SfsBaseDataRequestInputBase input) + { + return await _splitPackingRecApp.GetAllListByFilterAsync(input).ConfigureAwait(false); + } +} diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Jobs/ContainerJobController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Jobs/ContainerJobController.cs new file mode 100644 index 000000000..758982be3 --- /dev/null +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Jobs/ContainerJobController.cs @@ -0,0 +1,213 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text.Json; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Polly.Caching; +using Volo.Abp; +using Volo.Abp.Application.Dtos; +using Volo.Abp.AspNetCore.Mvc; +using Win_in.Sfs.Auth.Application.Contracts; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Wms.Inventory.Application.Contracts; +using Win_in.Sfs.Wms.Store.Application.Contracts; + +namespace Win_in.Sfs.Wms.Pda.Controllers.Jobs; + +/// +/// +/// +[ApiController] +[Route($"{PdaHostConst.ROOT_ROUTE}job/container")] +public class ContainerJobController : AbpController +{ + private readonly IContainerJobAppService _containerJobAppService; + + private readonly IUserWorkGroupAppService _userWorkGroupAppService; + + private readonly IDictAppService _dictApp; + + /// + /// + /// + /// + /// + public ContainerJobController( + IContainerJobAppService containerJobAppService, + IDictAppService dictApp + , IUserWorkGroupAppService userWorkGroupAppService) + { + _userWorkGroupAppService = userWorkGroupAppService; + _containerJobAppService = containerJobAppService; + _dictApp=dictApp; + } + + /// + /// 获取任务详情 + /// + /// + /// + [HttpGet("{id}")] + + public virtual async Task> GetAsync(Guid id) + { + var result = await _containerJobAppService.GetAsync(id).ConfigureAwait(false); + return Ok(result); + } + + /// + /// 获取列表 筛选 + /// + /// + /// + [HttpPost("list")] + public virtual async Task> GetListAsync(SfsJobRequestInputBase sfsRequestDTO) + { + var list = await _containerJobAppService.GetPagedListByFilterAsync(sfsRequestDTO, true).ConfigureAwait(false); + return list; + } + + /// + /// 获取列表 + /// + /// + /// + /// + [HttpGet("list")] + public virtual async Task> GetListAsync(int pageSize, int pageIndex, bool isFinished) + { + var dtos = await _dictApp.GetByCodeAsync("ContainerSpecificationsType").ConfigureAwait(false); + + var status = new List(); + if(isFinished==true) + { + status.Add((int)EnumJobStatus.Done); + } + else + { + status.Add((int)EnumJobStatus.Open); + } + var jsonStatus = JsonSerializer.Serialize(status); + + var request = new SfsJobRequestInputBase + { + MaxResultCount = pageSize, + SkipCount = (pageIndex - 1) * pageSize, + Sorting = $"{nameof(ContainerJobDTO.CreationTime)} ASC", + Condition = new Condition + { + Filters = new List + { + new(nameof(ContainerJobDTO.JobStatus),jsonStatus,"In") + } + } + }; + + var list = await _containerJobAppService.GetPagedListByFilterAsync(request, true).ConfigureAwait(false); + foreach (var item in list.Items) + { + if(!string.IsNullOrEmpty(item.SpecificationsType)) + { + var dictName= dtos.Items.FirstOrDefault(t => t.Code == item.SpecificationsType); + item.SpecificationsTypeName = dictName.Name; + } + + + } + + return list; + } + + /// + /// 根据Job Number 获取任务列表 + /// + /// + /// + [HttpGet("by-number/{jobNumber}")] + public virtual async Task> GetByNumberAsync(string jobNumber) + { + var jobDto = await _containerJobAppService.GetByNumberAsync(jobNumber).ConfigureAwait(false); + if (jobDto == null) + { + throw new UserFriendlyException($"未找到编号为 {jobNumber} 的任务"); + } + var wlgCodes = await _userWorkGroupAppService.GetCodsOfCurrentUserAsync().ConfigureAwait(false); + if (!wlgCodes.Contains(jobDto.WorkGroupCode)) + { + return new NotFoundObjectResult($"任务属于工作组 {jobDto.WorkGroupCode}"); + } + if (jobDto.JobStatus == EnumJobStatus.Doing && jobDto.AcceptUserId != CurrentUser.Id) + { + return new NotFoundObjectResult($"任务正在被 {jobDto.AcceptUserName} 处理"); + } + return jobDto; + } + + /// + /// 获取任务数量 + /// + /// + [HttpGet("count")] + public virtual async Task> CountAsync() + { + var wlgCodes = await _userWorkGroupAppService.GetCodsOfCurrentUserAsync().ConfigureAwait(false); + var jsonCodes = JsonSerializer.Serialize(wlgCodes); + + var status = new List() { (int)EnumJobStatus.Open, (int)EnumJobStatus.Doing }; + var jsonStatus = JsonSerializer.Serialize(status); + + var request = new SfsJobRequestInputBase + { + Sorting = $"{nameof(ContainerJobDTO.Priority)} ASC", + Condition = new Condition + { + Filters = new List + { + new(nameof(ContainerJobDTO.WorkGroupCode),jsonCodes,"In"), + new(nameof(ContainerJobDTO.JobStatus),jsonStatus,"In") + } + } + }; + + var count = await _containerJobAppService.GetCountByFilterAsync(request).ConfigureAwait(false); + + return Ok(count); + } + + /// + /// 承接任务 + /// + /// + /// + [HttpPost("take/{id}")] + public virtual async Task TakeAsync(Guid id) + { + await _containerJobAppService.AcceptAsync(id).ConfigureAwait(false); + } + + /// + /// 取消承接任务 + /// + /// + /// + [HttpPost("cancel-take/{id}")] + public virtual async Task CancelTakeAsync(Guid id) + { + await _containerJobAppService.CancelAcceptAsync(id).ConfigureAwait(false); + } + + /// + /// 执行任务 + /// + /// + /// + /// + [HttpPost("finish/{id}")] + public virtual async Task FinishAsync(Guid id, [FromBody] ContainerJobDTO dto) + { + await _containerJobAppService.CompleteAsync(id, dto).ConfigureAwait(false); + } +} diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Labels/InventoryLabelController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Labels/InventoryLabelController.cs index 5f4960978..b7b4718fc 100644 --- a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Labels/InventoryLabelController.cs +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Labels/InventoryLabelController.cs @@ -1,4 +1,6 @@ namespace Win_in.Sfs.Wms.Pda.Controllers.Inventories; + +using System.Collections.Generic; using System.Threading.Tasks; using Microsoft.AspNetCore.Mvc; @@ -34,4 +36,31 @@ public class InventoryLabelController : AbpController { return await _labelAppService.GetByCodeAsync(code).ConfigureAwait(false); } + + /// + /// 生成箱码 + /// + /// + /// + /// + [HttpPost("generate-and-create/many/{count}")] + public virtual async Task> GenerateAndCreateManyAsync(InventoryLabelWithoutCodeCreateInput input, int count) + { + return await _labelAppService.GenerateAndCreateManyAsync(input, count).ConfigureAwait(false); + } + + /// + /// EOF系统接口 + /// 插入箱码记录表、插入拆箱记录表 + /// 是客户箱码,不需要LabelDefine + /// + /// + /// + [HttpPost("create-many-no-code-new")] + public virtual async Task> CreateManyByNoCode_NewAsync(List inputs) + { + return await _labelAppService.CreateManyByNoCode_NewAsync(inputs).ConfigureAwait(false); + } + + } diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ContainerNoteController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ContainerNoteController.cs new file mode 100644 index 000000000..9a5a39473 --- /dev/null +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ContainerNoteController.cs @@ -0,0 +1,38 @@ +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp.AspNetCore.Mvc; +using Win_in.Sfs.Wms.Store.Application.Contracts; + +namespace Win_in.Sfs.Wms.Pda.Controllers.Stores; + +/// +/// +/// +[ApiController] +[Route($"{PdaHostConst.ROOT_ROUTE}store/container")] + +public class ContainerNoteController : AbpController +{ + private readonly IContainerNoteAppService _containerNoteAppService; + + /// + /// + /// + /// + public ContainerNoteController(IContainerNoteAppService containerNoteAppService) + { + _containerNoteAppService = containerNoteAppService; + } + + /// + /// 创建器具转移记录 + /// + /// CreateInput + /// + [HttpPost("")] + public virtual async Task CreateAsync(ContainerNoteEditInput input) + { + await _containerNoteAppService.CreateAsync(input).ConfigureAwait(false); + } + +} diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ContainerRequestController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ContainerRequestController.cs new file mode 100644 index 000000000..e93974d71 --- /dev/null +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/ContainerRequestController.cs @@ -0,0 +1,51 @@ +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp.AspNetCore.Mvc; +using Win_in.Sfs.Wms.Store.Application.Contracts; + +namespace Win_in.Sfs.Wms.Pda.Controllers.Stores; + +/// +///空器具呼叫请求 +/// +[ApiController] +[Route($"{PdaHostConst.ROOT_ROUTE}store/container-request")] + +public class ContainerRequestController : AbpController +{ + private readonly IContainerRequestAppService _containerRequestAppService; + + /// + /// + /// + /// + public ContainerRequestController(IContainerRequestAppService ContainerRequestAppService) + { + _containerRequestAppService = ContainerRequestAppService; + } + + /// + /// 空器具申请 + /// + /// + /// + [HttpPost("")] + public virtual async Task CreateAsync(ContainerRequestEditInput input) + { + _ = await _containerRequestAppService.CreateAsync(input).ConfigureAwait(false); + } + + /// + /// 根据number获取空器具申请详情 + /// + /// + /// + [HttpGet("{number}")] + + public virtual async Task> GetAsync(string number) + { + var result = await _containerRequestAppService.GetByNumberAsync(number).ConfigureAwait(false); + return Ok(result); + } + +} diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/IssueNoteController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/IssueNoteController.cs index 86c329304..f8ac25b4b 100644 --- a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/IssueNoteController.cs +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/IssueNoteController.cs @@ -39,6 +39,23 @@ public class IssueNoteController : AbpController { p.ToLot = string.Empty; p.ToPackingCode = string.Empty; + if(p.PositionCode.Contains('W')) + { + p.RecommendType = EnumRecommendType.W; + } + else if(p.PositionCode.Contains('Q')) + { + p.RecommendType = EnumRecommendType.Q; + } + else if (p.PositionCode.Contains('K')) + { + p.RecommendType = EnumRecommendType.K; + } + else + { + p.RecommendType = EnumRecommendType.None; + } + }); await _issueNoteAppService.CreateAsync(input).ConfigureAwait(false); diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/MaterialRequestController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/MaterialRequestController.cs index 13a0430b0..85bbc40ab 100644 --- a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/MaterialRequestController.cs +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/MaterialRequestController.cs @@ -25,14 +25,14 @@ public class MaterialRequestController : AbpController } /// - /// 创建要料申请(自动执行生成发料任务) + /// 扫描位置码创建要料申请(自动执行生成发料任务) /// /// /// [HttpPost("")] public virtual async Task CreateAsync(MaterialRequestEditInput input) { - _ = await _materialRequestAppService.CreateAndHandleAsync(input).ConfigureAwait(false); + _ = await _materialRequestAppService.CreateAndHandleByAPIAsync(input).ConfigureAwait(false); } /// diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/PurchaseReturnRequestController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/PurchaseReturnRequestController.cs new file mode 100644 index 000000000..e0ccaa4bf --- /dev/null +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/PurchaseReturnRequestController.cs @@ -0,0 +1,74 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp; +using Volo.Abp.AspNetCore.Mvc; +using Volo.Abp.Domain.Entities.Auditing; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Wms.Pda.Models; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Pda.Controllers.Stores; + +[ApiController] +[Route($"{PdaHostConst.ROOT_ROUTE}store/purchase-return-request")] +public class PurchaseReturnRequestController : AbpController +{ + private readonly IPurchaseReturnRequestAppService _purchaseReturnRequestAppService; + private readonly ITransactionTypeAppService _transactionTypeAppService; + public PurchaseReturnRequestController(IPurchaseReturnRequestAppService purchaseReturnRequestAppService, + ITransactionTypeAppService transactionTypeAppService + ) + { + _purchaseReturnRequestAppService = purchaseReturnRequestAppService; + _transactionTypeAppService = transactionTypeAppService; + } + + /// + /// 创建退货申请 + /// + [HttpPost("create-many")] + public virtual async Task CreateManyAsync(List input) + { + List entitys = new List(); + var groups = input.GroupBy(r => r.AsnNumber).ToList(); + foreach (var group in groups) + { + var list = group.ToList(); + var entity = ObjectMapper.Map(list[0]); + await SetRequestAutoPropertiesAsync(entity).ConfigureAwait(false); + entity.Details = new List(); + foreach (var item in list) + { + var detail = ObjectMapper.Map(list[0]); + entity.Details.Add(detail); + } + entitys.Add(entity); + } + await _purchaseReturnRequestAppService.CreateManyAsync(entitys).ConfigureAwait(false); + return Ok(); + } + + /// + /// 赋值Request业务属性 + /// + /// + /// + private async Task SetRequestAutoPropertiesAsync(PurchaseReturnRequestEditInput entity) + { + var tranType = await _transactionTypeAppService.GetByTransTypeAsync(EnumTransType.PurchaseReturn, EnumTransSubType.None).ConfigureAwait(false); + + Check.NotNull(tranType, "事务类型", "事务类型不存在"); + + entity.AutoCompleteJob = tranType.AutoCompleteJob; + entity.AutoSubmit = tranType.AutoSubmitRequest; + entity.AutoAgree = tranType.AutoAgreeRequest; + entity.AutoHandle = tranType.AutoHandleRequest; + entity.DirectCreateNote = tranType.DirectCreateNote; + } +} diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/TransferNoteController.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/TransferNoteController.cs index 5aac89ecc..dfcc5ce45 100644 --- a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/TransferNoteController.cs +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Controllers/Stores/TransferNoteController.cs @@ -144,4 +144,44 @@ public class TransferNoteController : AbpController { return await _transferNoteAppService.CreateAsync(input).ConfigureAwait(false); } + + /// + /// 拆箱 + /// + /// + /// + [HttpPost("split-packing")] + public async Task SplitPackingAsync(TransferNoteEditInput transferNoteEditInput) + { + return await _transferNoteAppService.SplitPackingAsync(transferNoteEditInput).ConfigureAwait(false); + } + + /// + /// 采购收货拆箱,同时更新、插入PurchaseReceipt任务表、申请表 + /// + /// + /// + /// + [HttpPost("split-packing-purchase-receipt")] + public async Task SplitPacking_PurchaseReceiptAsync(TransferNoteEditInput transferNoteEditInput, [FromQuery] SplitPacking_UpdateJobDetailInput updateJobDetailInput) + { + var ret = await _transferNoteAppService.SplitPacking_PurchaseReceiptAsync(transferNoteEditInput, updateJobDetailInput).ConfigureAwait(false); + return ret; + } + + /// + /// 发料拆箱,同时更新、插入Inspect任务表(没有找到申请表//??) + /// + /// + /// + /// + [HttpPost("split-packing-issue")] + public async Task SplitPacking_IssueAsync(TransferNoteEditInput transferNoteEditInput, [FromQuery] SplitPacking_UpdateJobDetailInput updateJobDetailInput) + { + var ret = await _transferNoteAppService.SplitPacking_IssueAsync(transferNoteEditInput, updateJobDetailInput).ConfigureAwait(false); + return ret; + } + + + } diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/PdaHostAutoMapperProfile.cs b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/PdaHostAutoMapperProfile.cs index bb3482baa..862e848b7 100644 --- a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/PdaHostAutoMapperProfile.cs +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/PdaHostAutoMapperProfile.cs @@ -2,6 +2,7 @@ using AutoMapper; using Volo.Abp.AutoMapper; using Win_in.Sfs.Wms.Pda.Controllers.Jobs; using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; namespace Win_in.Sfs.Wms.Pda; @@ -19,6 +20,15 @@ public class PdaHostAutoMapperProfile : Profile .Ignore(x => x.TimeWindow) .Ignore(x => x.SupplierName) ; + CreateMap() + .Ignore(x => x.ReturnType) + .Ignore(x => x.ReturnTime) + .Ignore(x => x.ActiveDate) + .Ignore(x => x.Details) + .Ignore(x => x.TenantId) + .Ignore(x => x.Remark) + .Ignore(x => x.ExtraProperties); + CreateMap(); } } diff --git a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Properties/PublishProfiles/FolderProfile.pubxml b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Properties/PublishProfiles/FolderProfile.pubxml index 5c6a0af51..000e05ebd 100644 --- a/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Properties/PublishProfiles/FolderProfile.pubxml +++ b/be/Hosts/WmsPda.Host/Win_in.Sfs.Wms.Pda.Host/Properties/PublishProfiles/FolderProfile.pubxml @@ -10,11 +10,11 @@ https://go.microsoft.com/fwlink/?LinkID=208121. Release Any CPU FileSystem - .\..\..\..\OutPut\PDA\ + D:\发布\WMS\pda FileSystem net6.0 6ea3cf3a-0bb9-49eb-8537-0cb7107052e2 false - + \ No newline at end of file diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Boms/IBomAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Boms/IBomAppService.cs index 8c6c78a4f..1084d0dbd 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Boms/IBomAppService.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Boms/IBomAppService.cs @@ -33,4 +33,13 @@ public interface IBomAppService Task> GetListOfComponentAsync(string component); Task AddOrUpsertListAsync(List inputs); Task UpsertAsyncByInterface(BomEditInput input); + + /// + /// 根据总成号、总成数量取所有子物料及其汇总数量 + /// + /// 总成号 + /// 总成数量 + /// + Task> GetMaterialTotalQtyAsync(string productCode, int productNum); + } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentAreaDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentAreaDTO.cs new file mode 100644 index 000000000..e76d96af3 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentAreaDTO.cs @@ -0,0 +1,54 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +using System; +using System.Collections.Generic; + +[Display(Name = "器具基本信息")] + +public class EquipmentAreaDTO : SfsBaseDataDTOBase, IHasCode +{ + /// + /// 器具编号 + /// + [Display(Name = "器具编号")] + public string Code { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + public string Type { get; set; } = string.Empty; + /// + /// 型号 + /// + [Display(Name = "型号")] + public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "库位编号")] + public string LocCode { get; set; } = string.Empty; + /// + /// 状态 + /// + [Display(Name = "状态")] + public int State { get; set; } = 0; + + + /// + /// 位置编号 + /// + [Display(Name = "位置编号")] + public string AreaCode { get; set; } + + + /// + /// 数量 + /// + [Display(Name = "数量")] + public decimal Qty { get; set; } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentAreaForDongyangExportDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentAreaForDongyangExportDTO.cs new file mode 100644 index 000000000..baae6ceca --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentAreaForDongyangExportDTO.cs @@ -0,0 +1,49 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "物料信息")] +public class EquipmentAreaForDongyangExportDTO +{ + /// + /// 器具编号 + /// + [Display(Name = "器具编号")] + public string Code { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + public string Type { get; set; } = string.Empty; + /// + /// 型号 + /// + [Display(Name = "型号")] + public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "库位编号")] + public string LocCode { get; set; } = string.Empty; + /// + /// 状态 + /// + [Display(Name = "状态")] + public int State { get; set; } = 0; + + + /// + /// 位置编号 + /// + [Display(Name = "位置编号")] + public string AreaCode { get; set; } + + + /// + /// 数量 + /// + [Display(Name = "数量")] + public decimal Qty { get; set; } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentDTO.cs new file mode 100644 index 000000000..c61f712b2 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentDTO.cs @@ -0,0 +1,64 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +using System; +using System.Collections.Generic; +using Win_in.Sfs.Shared.Domain.Shared.Enums.Basedata; + +[Display(Name = "器具基本信息")] + +public class EquipmentDTO : SfsBaseDataDTOBase, IHasCode +{ + /// + /// 类型 + /// + [Display(Name = "类型")] + public EnumEquipmentType Type { get; set; } + /// + /// 器具编号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + + /// + /// 标包数量 + /// + [Display(Name = "标包数")] + [Required(ErrorMessage = "{0}是必填项")] + public decimal StdQty { get; set; } + + /// + /// 型号 + /// + [Display(Name = "型号")] + public EnumEquipmentModel Model { get; set; } + /// + /// 库位编号 + /// + [Display(Name = "库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string LocCode { get; set; } = string.Empty; + /// + /// 状态 + /// + + [Display(Name = "状态")] + public int State { get; set; } = 0; + + /// + /// 创建人 + /// + [Display(Name = "创建人")] + public string Creator { get; set; } + + /// + /// 创建时间 + /// + [Display(Name = "创建时间")] + public DateTime CreatTime { get; set; } = DateTime.Now; +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentForDongyangExportDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentForDongyangExportDTO.cs new file mode 100644 index 000000000..e8308d52b --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentForDongyangExportDTO.cs @@ -0,0 +1,53 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "物料信息")] +public class EquipmentForDongyangExportDTO +{ + /// + /// 器具编号 + /// + [Display(Name = "器具编号")] + public string Code { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + public string Type { get; set; } = string.Empty; + /// + /// 型号 + /// + [Display(Name = "型号")] + public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "库位编号")] + public string LocCode { get; set; } = string.Empty; + /// + /// 状态 + /// + [Display(Name = "状态")] + public int State { get; set; } = 0; + /// + /// 备注 + /// + [Display(Name = "备注")] + public string Remark { get; set; } = string.Empty; + + + /// + /// 创建人 + /// + [Display(Name = "创建人")] + public string Creator { get; set; } + + /// + /// 创建时间 + /// + [Display(Name = "创建时间")] + public DateTime CreatTime { get; set; } = DateTime.Now; +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentLocCapDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentLocCapDTO.cs new file mode 100644 index 000000000..6a4ad91ce --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentLocCapDTO.cs @@ -0,0 +1,40 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + + + +[Display(Name = "器具容量占用信息")] + +public class EquipmentLocCapDTO : SfsBaseDataDTOBase, IHasCode +{ + /// + /// 器具代码 + /// + [Display(Name = "器具代码")] + public string Code { get; set; } + /// 占用百分比 + /// + [Display(Name = "占用百分比")] + public decimal Percent { get; set; } + + + /// + /// 零件号 + /// + public string PartCode { get; set; } + + /// + /// 录入数量 + /// + public decimal Qty { get; set; } + + /// + /// 标包数量 + /// + public decimal StdQty { get; set; } + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentLocDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentLocDTO.cs new file mode 100644 index 000000000..6833d79ca --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentLocDTO.cs @@ -0,0 +1,31 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +using System; +using System.Collections.Generic; + +[Display(Name = "器具库位关系")] + +public class EquipmentLocDTO : SfsBaseDataDTOBase, IHasCode +{ + + /// + /// 器具编号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + /// + /// 库位编号 + /// + [Display(Name = "库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string LocCode { get; set; } + + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentPartCodeDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentPartCodeDTO.cs new file mode 100644 index 000000000..2a6510242 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentPartCodeDTO.cs @@ -0,0 +1,73 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +using System; +using System.Collections.Generic; + +[Display(Name = "器具零件关系信息")] + +public class EquipmentPartCodeDTO : SfsBaseDataDTOBase, IHasCode +{ + + /// + /// 器具代号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + + ///// + ///// 型号 + ///// + //[Display(Name = "型号")] + //public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "零件代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string PartCode { get; set; } + + + + /// + /// 标包数量 + /// + [Display(Name = "标包数")] + [Required(ErrorMessage = "{0}是必填项")] + public decimal StdQty { get; set; } + + + + /// + /// 单位 + /// + [Display(Name = "单位")] + public string Unit { get; set; } + + + + + /// + /// 状态 + /// + + //[Display(Name = "状态")] + //public int State { get; set; } = 0; + + ///// + ///// 创建人 + ///// + //[Display(Name = "创建人")] + //public string Creator { get; set; } + + ///// + ///// 创建时间 + ///// + //[Display(Name = "创建时间")] + //public DateTime CreatTime { get; set; } = DateTime.Now; +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentRecordErrorDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentRecordErrorDTO.cs new file mode 100644 index 000000000..dc82187c1 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/DTOs/EquipmentRecordErrorDTO.cs @@ -0,0 +1,19 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Basedata.Equipments.DTOs; +[Display(Name = "器具校验信息")] +public class EquipmentRecordErrorDTO +{ + [Display(Name = "器具代码")] + public string EqptCode { set; get; } + [Display(Name = "零件代码")] + public string PartCode { set; get; } + [Display(Name = "错误信息")] + public string Error { set; get; } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/EquipmentAreaPermissions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/EquipmentAreaPermissions.cs new file mode 100644 index 000000000..04fa48623 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/EquipmentAreaPermissions.cs @@ -0,0 +1,21 @@ +using Volo.Abp.Authorization.Permissions; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public static class EquipmentAreaPermissions +{ + + public const string Default = BasedataPermissions.GroupName + "." + nameof(Equipment); + public const string Create = Default + "." + BasedataPermissions.CreateStr; + public const string Update = Default + "." + BasedataPermissions.UpdateStr; + public const string Delete = Default + "." + BasedataPermissions.DeleteStr; + + public static void AddEquipmentPermission(this PermissionGroupDefinition permissionGroup) + { + var EquipmentPermission = permissionGroup.AddPermission(Default, BasedataPermissionDefinitionProvider.L(nameof(Equipment))); + EquipmentPermission.AddChild(Create, BasedataPermissionDefinitionProvider.L(BasedataPermissions.CreateStr)); + EquipmentPermission.AddChild(Update, BasedataPermissionDefinitionProvider.L(BasedataPermissions.UpdateStr)); + EquipmentPermission.AddChild(Delete, BasedataPermissionDefinitionProvider.L(BasedataPermissions.DeleteStr)); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/EquipmentPermissions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/EquipmentPermissions.cs new file mode 100644 index 000000000..48f3a686f --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/EquipmentPermissions.cs @@ -0,0 +1,21 @@ +using Volo.Abp.Authorization.Permissions; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public static class EquipmentPermissions +{ + + public const string Default = BasedataPermissions.GroupName + "." + nameof(Equipment); + public const string Create = Default + "." + BasedataPermissions.CreateStr; + public const string Update = Default + "." + BasedataPermissions.UpdateStr; + public const string Delete = Default + "." + BasedataPermissions.DeleteStr; + + public static void AddEquipmentPermission(this PermissionGroupDefinition permissionGroup) + { + var EquipmentPermission = permissionGroup.AddPermission(Default, BasedataPermissionDefinitionProvider.L(nameof(Equipment))); + EquipmentPermission.AddChild(Create, BasedataPermissionDefinitionProvider.L(BasedataPermissions.CreateStr)); + EquipmentPermission.AddChild(Update, BasedataPermissionDefinitionProvider.L(BasedataPermissions.UpdateStr)); + EquipmentPermission.AddChild(Delete, BasedataPermissionDefinitionProvider.L(BasedataPermissions.DeleteStr)); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentAppService.cs new file mode 100644 index 000000000..9b4d3f1ba --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentAppService.cs @@ -0,0 +1,28 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public interface IEquipmentAppService + : ISfsBaseDataAppServiceBase + , ISfsGetByCodeAppService + , ISfsCheckAppService + , ISfsUpsertAppService +{ + //Task CheckItemIsAvailable(string itemCode); + //[HttpGet("check-item-is-available-no-select-sql")] + //void CheckItemIsAvailable(EquipmentDTO EquipmentDTO); + + //Task> GetListByNameAsync(string name); + + //Task GetOrAddAsync(EquipmentEditInput input); + + //Task GetManageTypeAsync(string itemCode); + //Task> GetManageTypesAsync(List itemCodes); + + //Task UpsertAsyncByInterface(EquipmentEditInput input); + //Task UpsertStdPackQtyAsync(string itemCode, decimal stdpackqty); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentAreaAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentAreaAppService.cs new file mode 100644 index 000000000..8067e9014 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentAreaAppService.cs @@ -0,0 +1,28 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public interface IEquipmentAreaAppService + : ISfsBaseDataAppServiceBase + , ISfsGetByCodeAppService + , ISfsCheckAppService + , ISfsUpsertAppService +{ + //Task CheckItemIsAvailable(string itemCode); + //[HttpGet("check-item-is-available-no-select-sql")] + //void CheckItemIsAvailable(EquipmentDTO EquipmentDTO); + + //Task> GetListByNameAsync(string name); + + //Task GetOrAddAsync(EquipmentEditInput input); + + //Task GetManageTypeAsync(string itemCode); + //Task> GetManageTypesAsync(List itemCodes); + + //Task UpsertAsyncByInterface(EquipmentEditInput input); + //Task UpsertStdPackQtyAsync(string itemCode, decimal stdpackqty); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentLocAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentLocAppService.cs new file mode 100644 index 000000000..0966b0b7a --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentLocAppService.cs @@ -0,0 +1,33 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public interface IEquipmentLocAppService + : ISfsBaseDataAppServiceBase + , ISfsGetByCodeAppService + , ISfsCheckAppService + , ISfsUpsertAppService +{ + + + Task> GetEquipmentLocAsync(List p_ls); + Task> GetLocsAsync(); + + //Task CheckItemIsAvailable(string itemCode); + //[HttpGet("check-item-is-available-no-select-sql")] + //void CheckItemIsAvailable(EquipmentLocDTO EquipmentLocDTO); + + //Task> GetListByNameAsync(string name); + + //Task GetOrAddAsync(EquipmentLocEditInput input); + + //Task GetManageTypeAsync(string itemCode); + //Task> GetManageTypesAsync(List itemCodes); + + //Task UpsertAsyncByInterface(EquipmentLocEditInput input); + //Task UpsertStdPackQtyAsync(string itemCode, decimal stdpackqty); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentLocCapAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentLocCapAppService.cs new file mode 100644 index 000000000..dfe01c9b7 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentLocCapAppService.cs @@ -0,0 +1,28 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public interface IEquipmentLocCapAppService + : ISfsBaseDataAppServiceBase + , ISfsGetByCodeAppService + , ISfsCheckAppService + , ISfsUpsertAppService +{ + //Task CheckItemIsAvailable(string itemCode); + //[HttpGet("check-item-is-available-no-select-sql")] + //void CheckItemIsAvailable(EquipmentLocCapDTO EquipmentLocCapDTO); + + //Task> GetListByNameAsync(string name); + + //Task GetOrAddAsync(EquipmentLocCapEditInput input); + + //Task GetManageTypeAsync(string itemCode); + //Task> GetManageTypesAsync(List itemCodes); + + //Task UpsertAsyncByInterface(EquipmentLocCapEditInput input); + //Task UpsertStdPackQtyAsync(string itemCode, decimal stdpackqty); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentPartCodeAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentPartCodeAppService.cs new file mode 100644 index 000000000..03bd162eb --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/IEquipmentPartCodeAppService.cs @@ -0,0 +1,31 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Mvc; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public interface IEquipmentPartCodeAppService + : ISfsBaseDataAppServiceBase + , ISfsGetByCodeAppService + + , ISfsUpsertAppService +{ + + + Task> GetEquipmentPartCodesAsync(List p_ls); + //Task CheckItemIsAvailable(string itemCode); + //[HttpGet("check-item-is-available-no-select-sql")] + //void CheckItemIsAvailable(EquipmentPartCodeDTO EquipmentPartCodeDTO); + + //Task> GetListByNameAsync(string name); + + //Task GetOrAddAsync(EquipmentPartCodeEditInput input); + + //Task GetManageTypeAsync(string itemCode); + //Task> GetManageTypesAsync(List itemCodes); + + //Task UpsertAsyncByInterface(EquipmentPartCodeEditInput input); + //Task UpsertStdPackQtyAsync(string itemCode, decimal stdpackqty); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentAreaCheckInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentAreaCheckInput.cs new file mode 100644 index 000000000..9b149c6e7 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentAreaCheckInput.cs @@ -0,0 +1,51 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class EquipmentAreaCheckInput +{ + /// + /// 器具编号 + /// + [Display(Name = "器具编号")] + public string Code { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + public string Type { get; set; } = string.Empty; + /// + /// 型号 + /// + [Display(Name = "型号")] + public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "库位编号")] + public string LocCode { get; set; } = string.Empty; + /// + /// 状态 + /// + [Display(Name = "状态")] + public int State { get; set; } = 0; + + + /// + /// 位置编号 + /// + [Display(Name = "位置编号")] + public string AreaCode { get; set; } + + + /// + /// 数量 + /// + [Display(Name = "数量")] + public decimal Qty { get; set; } + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentAreaEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentAreaEditInput.cs new file mode 100644 index 000000000..be0f614ca --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentAreaEditInput.cs @@ -0,0 +1,225 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class EquipmentAreaEditInput : SfsBaseDataCreateOrUpdateInputBase +{ + /// + /// 器具编号 + /// + [Display(Name = "器具编号")] + public string Code { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + public string Type { get; set; } = string.Empty; + /// + /// 型号 + /// + [Display(Name = "型号")] + public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "库位编号")] + public string LocCode { get; set; } = string.Empty; + /// + /// 状态 + /// + [Display(Name = "状态")] + public int State { get; set; } = 0; + + + /// + /// 位置编号 + /// + [Display(Name = "位置编号")] + public string AreaCode { get; set; } + + + /// + /// 数量 + /// + [Display(Name = "数量")] + public decimal Qty { get; set; } + + + + //#region Base + ///// + ///// 名称 + ///// + //[Display(Name = "名称")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Name { get; set; } + + ///// + ///// 描述1 + ///// + //[Display(Name = "描述1")] + //[StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Desc1 { get; set; } + + ///// + ///// 描述2 + ///// + //[Display(Name = "描述2")] + //[StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Desc2 { get; set; } + + ///// + ///// 状态 + ///// + //[Display(Name = "状态")] + //[Required(ErrorMessage = "{0}是必填项")] + //public EnumItemStatus Status { get; set; } + + ///// + ///// 制造件 + ///// + //[Display(Name = "制造件")] + //[Required(ErrorMessage = "{0}是必填项")] + //public bool CanMake { get; set; } + + ///// + ///// 采购件 + ///// + //[Display(Name = "采购件")] + //[Required(ErrorMessage = "{0}是必填项")] + //public bool CanBuy { get; set; } + ///// + ///// 外包件 + ///// + //[Display(Name = "外包件")] + //public bool CanOutsourcing { get; set; } + ///// + ///// 回收件 + ///// + //[Display(Name = "回收件")] + //public bool IsRecycled { get; set; } + + ///// + ///// 类型 + ///// + //[Display(Name = "类型")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Type { get; set; } + + ///// + ///// 种类 + ///// + //[Display(Name = "种类")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Category { get; set; } + + ///// + ///// 分组 + ///// + //[Display(Name = "分组")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Group { get; set; } + + ///// + ///// 颜色 + ///// + //[Display(Name = "颜色")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Color { get; set; } + + ///// + ///// 配置 + ///// + //[Display(Name = "配置")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Configuration { get; set; } + + ///// + ///// 虚零件 + ///// + //[Display(Name = "虚零件(Is phantom)")] + //public virtual bool IsPhantom { get; set; } + + ///// + ///// 基本计量单位 + ///// + //[Display(Name = "基本计量单位")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string BasicUom { get; set; } + + ///// + ///// 标包数 + ///// + //[Display(Name = "标包数")] + //[Required(ErrorMessage = "{0}是必填项")] + //public decimal StdPackQty { get; set; } + + ///// + ///// ABC类 + ///// + //[Display(Name = "ABC类")] + //[Required(ErrorMessage = "{0}是必填项", AllowEmptyStrings = true)] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string AbcClass { get; set; } + + ///// + ///// 项目 + ///// + //[Display(Name = "项目")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Project { get; set; } + + ///// + ///// 版本 + ///// + //[Display(Name = "版本")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Version { get; set; } + + ///// + ///// 工程变革 + ///// + //[Display(Name = "工程变革")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Eco { get; set; } + + ///// + ///// 有效期 + ///// + //[Display(Name = "有效期")] + //public int Validity { get; set; } + ///// + ///// 有效期单位 + ///// + //[Display(Name = "有效期单位")] + //public EnumValidityUnit ValidityUnit { get; set; } + + ///// + ///// 管理类型 + ///// + //[Display(Name = "管理类型")] + //public EnumItemManageType ManageType { get; set; } + + ///// + ///// 打印标签用的一个等级 + ///// + //[Display(Name = "Elevel")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Elevel { get; set; } + //#endregion + + //#region Create + ///// + ///// 代码 + ///// + //[Display(Name = "代码")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Code { get; set; } + //#endregion +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentAreaImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentAreaImportInput.cs new file mode 100644 index 000000000..b306348dd --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentAreaImportInput.cs @@ -0,0 +1,53 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "器具位置")] +public class EquipmentAreaImportInput : SfsBaseDataImportInputBase +{ + /// + /// 器具编号 + /// + [Display(Name = "器具编号")] + public string Code { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + public string Type { get; set; } = string.Empty; + /// + /// 型号 + /// + [Display(Name = "型号")] + public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "库位编号")] + public string LocCode { get; set; } = string.Empty; + /// + /// 状态 + /// + [Display(Name = "状态")] + public int State { get; set; } = 0; + + + /// + /// 位置编号 + /// + [Display(Name = "位置编号")] + public string AreaCode { get; set; } + + + /// + /// 数量 + /// + [Display(Name = "数量")] + public decimal Qty { get; set; } + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentCheckInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentCheckInput.cs new file mode 100644 index 000000000..33d5ffc19 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentCheckInput.cs @@ -0,0 +1,55 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class EquipmentCheckInput +{ + /// + /// 器具编号 + /// + [Display(Name = "器具编号")] + public string Code { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + public string Type { get; set; } = string.Empty; + /// + /// 型号 + /// + [Display(Name = "型号")] + public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "库位编号")] + public string LocCode { get; set; } = string.Empty; + /// + /// 状态 + /// + [Display(Name = "状态")] + public int State { get; set; } = 0; + /// + /// 备注 + /// + [Display(Name = "备注")] + public string Remark { get; set; } = string.Empty; + + + /// + /// 创建人 + /// + [Display(Name = "创建人")] + public string Creator { get; set; } + + /// + /// 创建时间 + /// + [Display(Name = "创建时间")] + public DateTime CreatTime { get; set; }=DateTime.Now; + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentEditInput.cs new file mode 100644 index 000000000..e5fe9a2e5 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentEditInput.cs @@ -0,0 +1,236 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.Domain.Shared.Enums.Basedata; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class EquipmentEditInput : SfsBaseDataCreateOrUpdateInputBase +{ + /// + /// 类型 + /// + [Display(Name = "类型")] + public EnumEquipmentType Type { get; set; } + /// + /// 器具编号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + + /// + /// 标包数量 + /// + [Display(Name = "标包数")] + [Required(ErrorMessage = "{0}是必填项")] + public decimal StdQty { get; set; } + + /// + /// 型号 + /// + [Display(Name = "型号")] + public EnumEquipmentModel Model { get; set; } + /// + /// 库位编号 + /// + [Display(Name = "库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string LocCode { get; set; } = string.Empty; + /// + /// 状态 + /// + + [Display(Name = "状态")] + public int State { get; set; } = 0; + + /// + /// 创建人 + /// + [Display(Name = "创建人")] + public string Creator { get; set; } + + /// + /// 创建时间 + /// + [Display(Name = "创建时间")] + public DateTime CreatTime { get; set; }=DateTime.Now; + + + + //#region Base + ///// + ///// 名称 + ///// + //[Display(Name = "名称")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Name { get; set; } + + ///// + ///// 描述1 + ///// + //[Display(Name = "描述1")] + //[StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Desc1 { get; set; } + + ///// + ///// 描述2 + ///// + //[Display(Name = "描述2")] + //[StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Desc2 { get; set; } + + ///// + ///// 状态 + ///// + //[Display(Name = "状态")] + //[Required(ErrorMessage = "{0}是必填项")] + //public EnumItemStatus Status { get; set; } + + ///// + ///// 制造件 + ///// + //[Display(Name = "制造件")] + //[Required(ErrorMessage = "{0}是必填项")] + //public bool CanMake { get; set; } + + ///// + ///// 采购件 + ///// + //[Display(Name = "采购件")] + //[Required(ErrorMessage = "{0}是必填项")] + //public bool CanBuy { get; set; } + ///// + ///// 外包件 + ///// + //[Display(Name = "外包件")] + //public bool CanOutsourcing { get; set; } + ///// + ///// 回收件 + ///// + //[Display(Name = "回收件")] + //public bool IsRecycled { get; set; } + + ///// + ///// 类型 + ///// + //[Display(Name = "类型")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Type { get; set; } + + ///// + ///// 种类 + ///// + //[Display(Name = "种类")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Category { get; set; } + + ///// + ///// 分组 + ///// + //[Display(Name = "分组")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Group { get; set; } + + ///// + ///// 颜色 + ///// + //[Display(Name = "颜色")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Color { get; set; } + + ///// + ///// 配置 + ///// + //[Display(Name = "配置")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Configuration { get; set; } + + ///// + ///// 虚零件 + ///// + //[Display(Name = "虚零件(Is phantom)")] + //public virtual bool IsPhantom { get; set; } + + ///// + ///// 基本计量单位 + ///// + //[Display(Name = "基本计量单位")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string BasicUom { get; set; } + + ///// + ///// 标包数 + ///// + //[Display(Name = "标包数")] + //[Required(ErrorMessage = "{0}是必填项")] + //public decimal StdPackQty { get; set; } + + ///// + ///// ABC类 + ///// + //[Display(Name = "ABC类")] + //[Required(ErrorMessage = "{0}是必填项", AllowEmptyStrings = true)] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string AbcClass { get; set; } + + ///// + ///// 项目 + ///// + //[Display(Name = "项目")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Project { get; set; } + + ///// + ///// 版本 + ///// + //[Display(Name = "版本")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Version { get; set; } + + ///// + ///// 工程变革 + ///// + //[Display(Name = "工程变革")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Eco { get; set; } + + ///// + ///// 有效期 + ///// + //[Display(Name = "有效期")] + //public int Validity { get; set; } + ///// + ///// 有效期单位 + ///// + //[Display(Name = "有效期单位")] + //public EnumValidityUnit ValidityUnit { get; set; } + + ///// + ///// 管理类型 + ///// + //[Display(Name = "管理类型")] + //public EnumItemManageType ManageType { get; set; } + + ///// + ///// 打印标签用的一个等级 + ///// + //[Display(Name = "Elevel")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Elevel { get; set; } + //#endregion + + //#region Create + ///// + ///// 代码 + ///// + //[Display(Name = "代码")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Code { get; set; } + //#endregion +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentImportInput.cs new file mode 100644 index 000000000..2894c5c1b --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentImportInput.cs @@ -0,0 +1,64 @@ +using System; +using System.ComponentModel.DataAnnotations; + +using Win_in.Sfs.Shared.Domain.Shared.Enums.Basedata; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "物品")] +public class EquipmentImportInput : SfsBaseDataImportInputBase +{ + /// + /// 类型 + /// + [Display(Name = "类型")] + public Win_in.Sfs.Shared.Domain.Shared.Enums.Basedata.EnumEquipmentType Type { get; set; } + /// + /// 器具编号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + + /// + /// 标包数量 + /// + [Display(Name = "标包数")] + [Required(ErrorMessage = "{0}是必填项")] + public decimal StdQty { get; set; } + + /// + /// 型号 + /// + [Display(Name = "型号")] + public EnumEquipmentModel Model { get; set; } + /// + /// 库位编号 + /// + [Display(Name = "库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string LocCode { get; set; } = string.Empty; + /// + /// 状态 + /// + + [Display(Name = "状态")] + public int State { get; set; } = 0; + + /// + /// 创建人 + /// + [Display(Name = "创建人")] + public string Creator { get; set; } + + /// + /// 创建时间 + /// + [Display(Name = "创建时间")] + public DateTime CreatTime { get; set; } = DateTime.Now; + + + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCapCheckInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCapCheckInput.cs new file mode 100644 index 000000000..d7b272c8e --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCapCheckInput.cs @@ -0,0 +1,20 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class EquipmentLocCapCheckInput +{ + /// + /// 器具代码 + /// + [Display(Name = "器具代码")] + public string Code { get; set; } + /// 占用百分比 + /// + [Display(Name = "占用百分比")] + public decimal Percent { get; set; } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCapEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCapEditInput.cs new file mode 100644 index 000000000..ef9146b56 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCapEditInput.cs @@ -0,0 +1,20 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.Domain.Shared.Enums.Basedata; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class EquipmentLocCapEditInput : SfsBaseDataCreateOrUpdateInputBase +{ + /// + /// 器具代码 + /// + [Display(Name = "器具代码")] + public string Code { get; set; } + /// 占用百分比 + /// + [Display(Name = "占用百分比")] + public decimal Percent { get; set; } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCapImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCapImportInput.cs new file mode 100644 index 000000000..796c95708 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCapImportInput.cs @@ -0,0 +1,38 @@ +using System; +using System.ComponentModel.DataAnnotations; + +using Win_in.Sfs.Shared.Domain.Shared.Enums.Basedata; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "器具容量")] +public class EquipmentLocCapImportInput : SfsBaseDataImportInputBase +{ + /// + /// 器具代码 + /// + [Display(Name = "器具代码")] + public string Code { get; set; } + /// 占用百分比 + /// + [Display(Name = "占用百分比")] + public decimal Percent { get; set; } + //[Display(Name = "零件代码")] + + //public string PartCode { get; set; } + + //[Display(Name = "当前数量")] + ///// + ///// 录入数量 + ///// + //public decimal Qty { get; set; } + //[Display(Name = "标包数量")] + ///// + ///// 标包数量 + ///// + //public decimal StdQty { get; set; } + + + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCheckInput .cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCheckInput .cs new file mode 100644 index 000000000..9b1473845 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocCheckInput .cs @@ -0,0 +1,27 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class EquipmentLocCheckInput +{ + + /// + /// 器具编号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + /// + /// 库位编号 + /// + [Display(Name = "库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string LocCode { get; set; } + + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocEditInput.cs new file mode 100644 index 000000000..0f2c0e919 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocEditInput.cs @@ -0,0 +1,28 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class EquipmentLocEditInput : SfsBaseDataCreateOrUpdateInputBase +{ + /// + /// 器具编号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + /// + /// 库位编号 + /// + [Display(Name = "库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string LocCode { get; set; } + + [Display(Name = "状态")] + public int State { get; set; } = 0; + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocImportInput.cs new file mode 100644 index 000000000..2dffe09b6 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentLocImportInput.cs @@ -0,0 +1,33 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "器具")] +public class EquipmentLocImportInput : SfsBaseDataImportInputBase +{ + /// + /// 器具编号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + /// + /// 库位编号 + /// + [Display(Name = "库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string LocCode { get; set; } + + + [Display(Name = "状态")] + public int State { get; set; } = 0; + + + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentPartCodeCheckInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentPartCodeCheckInput.cs new file mode 100644 index 000000000..2e8051cb1 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentPartCodeCheckInput.cs @@ -0,0 +1,43 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class EquipmentPartCodeCheckInput +{ + + /// + /// 器具代号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + + + + ///// + ///// 型号 + ///// + //[Display(Name = "型号")] + //public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "零件代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string PartCode { get; set; } + + + + /// + /// 标包数量 + /// + [Display(Name = "标包数")] + [Required(ErrorMessage = "{0}是必填项")] + public decimal StdQty { get; set; } + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentPartCodeEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentPartCodeEditInput.cs new file mode 100644 index 000000000..aa5b93511 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentPartCodeEditInput.cs @@ -0,0 +1,53 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class EquipmentPartCodeEditInput : SfsBaseDataCreateOrUpdateInputBase +{ + /// + /// 器具代号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + + + + ///// + ///// 型号 + ///// + //[Display(Name = "型号")] + //public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "零件代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string PartCode { get; set; } + + + + /// + /// 标包数量 + /// + [Display(Name = "标包数")] + [Required(ErrorMessage = "{0}是必填项")] + public decimal StdQty { get; set; } + + + + /// + /// 标包数量 + /// + [Display(Name = "单位")] + [Required(ErrorMessage = "{0}是必填项")] + public string Unit { get; set; } + + [Display(Name = "状态")] + public int State { get; set; } = 0; + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentPartCodeImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentPartCodeImportInput.cs new file mode 100644 index 000000000..77e58034e --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Equipments/Inputs/EquipmentPartCodeImportInput.cs @@ -0,0 +1,60 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "器具")] +public class EquipmentPartCodeImportInput : SfsBaseDataImportInputBase +{ + /// + /// 器具代号 + /// + [Display(Name = "器具代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + + + + + ///// + ///// 型号 + ///// + //[Display(Name = "型号")] + //public string Model { get; set; } = string.Empty; + /// + /// 库位编号 + /// + [Display(Name = "零件代码")] + [Required(ErrorMessage = "{0}是必填项")] + public string PartCode { get; set; } + + + + /// + /// 标包数量 + /// + [Display(Name = "标包数")] + [Required(ErrorMessage = "{0}是必填项")] + public decimal StdQty { get; set; } + + + /// + /// 标包数量 + /// + [Display(Name = "单位")] + [Required(ErrorMessage = "{0}是必填项")] + public string Unit { get; set; } + + + [Display(Name = "状态")] + public int State { get; set; } = 0; + + + + + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/DTOs/KittingDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/DTOs/KittingDTO.cs new file mode 100644 index 000000000..766c2706d --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/DTOs/KittingDTO.cs @@ -0,0 +1,41 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Volo.Abp.Application.Dtos; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "Kitting箱")] +public class KittingDTO : EntityDto, IHasCode, IHasName +{ + [Display(Name ="编号")] + public string Code { get; set; } + [Display(Name = "名称")] + public string Name { get; set; } + + [Display(Name = "明细")] + public List Details { set; get; }= new List(); +} + +public class KittingErrorDto +{ + + [Display(Name = "Kitting编号")] + public string Code { get; set; } + + + [Display(Name = "零件代码")] + public string PartCode { get; set; } + + + [Display(Name = "错误信息")] + public string Content { get; set; } + + + +} + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/DTOs/KittingDetailDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/DTOs/KittingDetailDTO.cs new file mode 100644 index 000000000..cfa860a62 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/DTOs/KittingDetailDTO.cs @@ -0,0 +1,49 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Volo.Abp.Application.Dtos; +using Volo.Abp.MultiTenancy; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "Kitting箱明细")] +public class KittingDetailDTO: AuditedEntityDto, IMultiTenant, IRemark +{ + /// + /// 主表ID + /// + [Display(Name = "主表ID")] + public Guid MasterId { get; set; } + /// + /// 物料编码 + /// + [Display(Name = "物料编码")] + public string PartCode { set; get; } + /// + /// 描述1 + /// + [Display(Name = "描述1")] + public string Desc1 { set; get; } + /// + /// 描述2 + /// + [Display(Name = "描述2")] + public string Desc2 { set; get; } + /// + /// 包装数量 + /// + [Display(Name = "包装数量")] + public decimal Qty { set; get; } + + /// + /// 配置 + /// + [Display(Name = "配置")] + public string Conf { set; get; } + + public Guid? TenantId { set; get; } + + public string Remark { get; set; } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/IKttingAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/IKttingAppService.cs new file mode 100644 index 000000000..ff56f5fab --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/IKttingAppService.cs @@ -0,0 +1,9 @@ +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Application.Contracts; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public interface IKittingAppService: ISfsBaseDataAppServiceBase, ISfsGetByCodeAppService +{ + Task UpdateAsync(KittingEditInput input); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/Inputs/KittingDetailInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/Inputs/KittingDetailInput.cs new file mode 100644 index 000000000..1b9e2a17b --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/Inputs/KittingDetailInput.cs @@ -0,0 +1,49 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Volo.Abp.Application.Dtos; +using Volo.Abp.MultiTenancy; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Kittings.Inputs; +public class KittingDetailInput: EntityDto, IMultiTenant, IRemark +{ + /// + /// 主表ID + /// + [Display(Name = "主表ID")] + public Guid MasterId { get; set; } + /// + /// 物料编码 + /// + [Display(Name = "物料编码")] + public string PartCode { set; get; } + /// + /// 描述1 + /// + [Display(Name = "描述1")] + public string Desc1 { set; get; } + /// + /// 描述2 + /// + [Display(Name = "描述2")] + public string Desc2 { set; get; } + /// + /// 包装数量 + /// + [Display(Name = "包装数量")] + public decimal Qty { set; get; } + /// + /// 配置 + /// + [Display(Name = "配置")] + public string Conf { set; get; } + [Display(Name = "租户ID")] + public Guid? TenantId { set; get; + } + [Display(Name = "备注")] + public string Remark { get; set; } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/Inputs/KittingEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/Inputs/KittingEditInput.cs new file mode 100644 index 000000000..75c7ac409 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/Inputs/KittingEditInput.cs @@ -0,0 +1,32 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.ComponentModel.DataAnnotations; +using Volo.Abp.Application.Dtos; +using Volo.Abp.Data; +using Volo.Abp.MultiTenancy; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Basedata.Kittings.Inputs; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class KittingEditInput : EntityDto, IMultiTenant, IRemark, IHasExtraProperties +{ + + public string Code { get; set; } + public string Name { get; set; } + + + public virtual List Details { get; set; }=new List(); + + [DefaultValue(null)] + public Guid? TenantId { get; set; } + + public string Remark { get; set; } + + [DefaultValue("{}")] + public ExtraPropertyDictionary ExtraProperties { get; set; } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/Inputs/KittingImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/Inputs/KittingImportInput.cs new file mode 100644 index 000000000..38f183eec --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/Inputs/KittingImportInput.cs @@ -0,0 +1,149 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "Kitting箱")] +public class KittingImportInput : SfsBaseDataImportInputBase +{ + /// + /// Kitting编码 + /// + [Display(Name ="Kitting编码")] + public string Code { get; set; } + /// + /// Kitting名称 + /// + [Display(Name = "Kitting名称")] + public string Name { get; set; } + /// + /// 物料编码 + /// + [Display(Name = "物料编码")] + public string PartCode { set; get; } + /// + /// 描述1 + /// + [Display(Name = "物料描述1")] + public string Desc1 { set; get; } + /// + /// 描述2 + /// + [Display(Name = "物料描述2")] + public string Desc2 { set; get; } + /// + /// 包装数量 + /// + [Display(Name = "包装数量")] + public decimal Qty { set; get; } + /// + /// 配置 + /// + [Display(Name = "配置")] + public string Conf { set; get; } + //[Display(Name = "租户ID")] + //public Guid? TenantId + //{ + // set; get; + //} + //[Display(Name = "备注")] + //public string Remark { get; set; } + + + + +} + +//[Serializable] +//public class CustomerDTO : SfsBaseDataDTOBase +//{ +// /// +// ///�ͻ����� +// /// +// [Display(Name = "�ͻ�����")] +// [Required(ErrorMessage = "{0}�DZ�����")] +// [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}�������{1}���ַ�")] +// public string Code { get; set; } + +// /// +// /// �ͻ����� +// /// +// [Display(Name = "�ͻ�����")] +// [Required(ErrorMessage = "{0}�DZ�����")] +// [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}�������{1}���ַ�")] +// public string Name { get; set; } + +// /// +// /// �ͻ����� +// /// +// [Display(Name = "�ͻ�����")] +// [StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}�������{1}���ַ�")] +// public string Description { get; set; } + +// /// +// /// ��ϵ��ַ +// /// +// [Display(Name = "��ϵ��ַ")] +// [StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}�������{1}���ַ�")] +// public string Address { get; set; } + +// /// +// /// ��ϵ�� +// /// + +// [Display(Name = "��ϵ��")] +// [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}�������{1}���ַ�")] +// public string Contact { get; set; } + +// /// +// /// ��ϵ�绰 +// /// +// [Display(Name = "��ϵ�绰")] +// public string ContactPhone { get; set; } + +// /// +// /// ��ϵ�ʼ� +// /// +// [Display(Name = "��ϵ�ʼ�")] + +// public string ContactEmail { get; set; } + +// /// +// /// ��ϵ���� +// /// +// [Display(Name = "��ϵ����")] +// public string ContactFax { get; set; } + +// /// +// /// ˰�� +// /// +// [Display(Name = "˰��")] +// public Nullable TaxRate { get; set; } + +// /// +// /// ����ID +// /// +// [Display(Name = "����Id")] +// public Guid CurrencyId { get; set; } + +// /// +// /// ����ID +// /// +// [Display(Name = "��������")] +// public string CurrencyName { get; set; } + +// /// +// /// �ͻ����� +// /// +// [Display(Name = "�ͻ�����")] +// public Nullable CustomerType { get; set; } + +// public bool Enabled { get; set; } + +// //public ICollection CustomerItems { set; get; } +//} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/KittingPermissions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/KittingPermissions.cs new file mode 100644 index 000000000..d2b46bfdd --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Kittings/KittingPermissions.cs @@ -0,0 +1,21 @@ +using Volo.Abp.Authorization.Permissions; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public static class KittingPermissions +{ + + public const string Default = BasedataPermissions.GroupName + "." + nameof(Kitting); + public const string Create = Default + "." + BasedataPermissions.CreateStr; + public const string Update = Default + "." + BasedataPermissions.UpdateStr; + public const string Delete = Default + "." + BasedataPermissions.DeleteStr; + + public static void AddKittingPermission(this PermissionGroupDefinition permissionGroup) + { + var customerPermission = permissionGroup.AddPermission(Default, BasedataPermissionDefinitionProvider.L(nameof(Kitting))); + customerPermission.AddChild(Create, BasedataPermissionDefinitionProvider.L(BasedataPermissions.CreateStr)); + customerPermission.AddChild(Update, BasedataPermissionDefinitionProvider.L(BasedataPermissions.UpdateStr)); + customerPermission.AddChild(Delete, BasedataPermissionDefinitionProvider.L(BasedataPermissions.DeleteStr)); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Permissions/BasedataPermissionDefinitionProvider.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Permissions/BasedataPermissionDefinitionProvider.cs index 120cfe889..761725ba0 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Permissions/BasedataPermissionDefinitionProvider.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Permissions/BasedataPermissionDefinitionProvider.cs @@ -30,11 +30,13 @@ public class BasedataPermissionDefinitionProvider : PermissionDefinitionProvider basedataGroup.AddSalePriceSheetPermission(); basedataGroup.AddShiftPermission(); basedataGroup.AddStdCostPriceSheetPermission(); + basedataGroup.AddSplitPackingRecPermission(); basedataGroup.AddUomPermission(); basedataGroup.AddItemBasicPermission(); basedataGroup.AddItemCategoryPermission(); basedataGroup.AddItemPackPermission(); basedataGroup.AddCategoryPermission(); + basedataGroup.AddPositionCodePermission(); basedataGroup.AddWorkShopPermission(); basedataGroup.AddDockPermission(); basedataGroup.AddLocationGroupPermission(); diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/DTOs/PositionCodeDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/DTOs/PositionCodeDTO.cs new file mode 100644 index 000000000..cce3aaeff --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/DTOs/PositionCodeDTO.cs @@ -0,0 +1,63 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "位置码")] + +public class PositionCodeDTO : SfsBaseDataDTOBase, IHasCode +{ + /// + /// 代码 + /// + [Display(Name = "代码")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string Code { get; set; } + /// + /// 物料号 + /// + [Display(Name = "物料号")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string PartCode { get; set; } + /// + /// 物料名称 + /// + [Display(Name = "物料名称")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string PartName { get; set; } + /// + /// 物料描述 + /// + [Display(Name = "物料描述")] + [StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string PartDesc { get; set; } + /// + /// 基本计量单位 + /// + [Display(Name = "基本计量单位")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string BasicUom { get; set; } + /// + /// 库位 + /// + [Display(Name = "库位")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string LocationCode { get; set; } + /// + /// 库位名称 + /// + [Display(Name = "库位名称")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string LocationName { get; set; } + /// + /// 标包数量 + /// + [Display(Name = "标包数量")] + public decimal StdPackQty { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + public EnumRecommendType Type { get; set; } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/IPositionCodeAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/IPositionCodeAppService.cs new file mode 100644 index 000000000..ffd61038e --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/IPositionCodeAppService.cs @@ -0,0 +1,9 @@ +using Win_in.Sfs.Shared.Application.Contracts; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public interface IPositionCodeAppService + : ISfsBaseDataAppServiceBase + , ISfsGetByCodeAppService +{ +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/Inputs/PositionCodeEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/Inputs/PositionCodeEditInput.cs new file mode 100644 index 000000000..6db7b8d01 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/Inputs/PositionCodeEditInput.cs @@ -0,0 +1,67 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Serializable] +public class PositionCodeEditInput : SfsBaseDataCreateOrUpdateInputBase +{ + #region Base + /// + /// 物料号 + /// + [Display(Name = "物料号")] + [Required(ErrorMessage = "{0}是必填项")] + public string PartCode { get; set; } + /// + /// 物料名称 + /// + [Display(Name = "物料名称")] + public string PartName { get; set; } + /// + /// 物料描述 + /// + [Display(Name = "物料描述")] + public string PartDesc { get; set; } + /// + /// 基本计量单位 + /// + [Display(Name = "基本计量单位")] + public string BasicUom { get; set; } + /// + /// 库位 + /// + [Display(Name = "库位")] + [Required(ErrorMessage = "{0}是必填项")] + public string LocationCode { get; set; } + /// + /// 库位名称 + /// + [Display(Name = "库位名称")] + public string LocationName { get; set; } + /// + /// 标包数量 + /// + [Display(Name = "标包数量")] + public decimal StdPackQty { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + [Required(ErrorMessage = "{0}是必填项")] + public EnumRecommendType Type { get; set; } + + #endregion + + #region Create + /// + /// 代码 + /// + [Display(Name = "代码")] + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string Code { get; set; } + #endregion +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/Inputs/PositionCodeImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/Inputs/PositionCodeImportInput.cs new file mode 100644 index 000000000..825994c1d --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/Inputs/PositionCodeImportInput.cs @@ -0,0 +1,68 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +[Display(Name = "位置码")] +public class PositionCodeImportInput : SfsBaseDataImportInputBase +{ + /// + /// 位置码 + /// + [Key] + [Display(Name = "位置码")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + [Required(ErrorMessage = "{0}是必填项")] + public string Code { get; set; } + /// + /// 物料号 + /// + [Display(Name = "物料号")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + [Required(ErrorMessage = "{0}是必填项")] + public string PartCode { get; set; } + /// + /// 物料名称 + /// + [Display(Name = "物料名称")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string PartName { get; set; } + /// + /// 物料描述 + /// + [Display(Name = "物料描述")] + [StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string PartDesc { get; set; } + /// + /// 基本计量单位 + /// + [Display(Name = "基本计量单位")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string BasicUom { get; set; } + /// + /// 库位 + /// + [Display(Name = "库位")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + [Required(ErrorMessage = "{0}是必填项")] + public string LocationCode { get; set; } + /// + /// 库位名称 + /// + [Display(Name = "库位名称")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string LocationName { get; set; } + /// + /// 标包数量 + /// + [Display(Name = "标包数量")] + public decimal StdPackQty { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + [Required(ErrorMessage = "{0}是必填项")] + public EnumRecommendType Type { get; set; } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/PositionCodePermissions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/PositionCodePermissions.cs new file mode 100644 index 000000000..596671428 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PositionCode/PositionCodePermissions.cs @@ -0,0 +1,21 @@ +using Volo.Abp.Authorization.Permissions; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public static class PositionCodePermissions +{ + + public const string Default = BasedataPermissions.GroupName + "." + nameof(PositionCode); + public const string Create = Default + "." + BasedataPermissions.CreateStr; + public const string Update = Default + "." + BasedataPermissions.UpdateStr; + public const string Delete = Default + "." + BasedataPermissions.DeleteStr; + + public static void AddPositionCodePermission(this PermissionGroupDefinition permissionGroup) + { + var positionCodePermission = permissionGroup.AddPermission(Default, BasedataPermissionDefinitionProvider.L(nameof(PositionCode))); + positionCodePermission.AddChild(Create, BasedataPermissionDefinitionProvider.L(BasedataPermissions.CreateStr)); + positionCodePermission.AddChild(Update, BasedataPermissionDefinitionProvider.L(BasedataPermissions.UpdateStr)); + positionCodePermission.AddChild(Delete, BasedataPermissionDefinitionProvider.L(BasedataPermissions.DeleteStr)); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/DTOs/PurchasePriceSheetDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/DTOs/PurchasePriceSheetDTO.cs index b1cc52eba..08a19b4a3 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/DTOs/PurchasePriceSheetDTO.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/DTOs/PurchasePriceSheetDTO.cs @@ -12,55 +12,33 @@ namespace Win_in.Sfs.Basedata.Application.Contracts; /// [Display(Name = "采购价格单")] -public class PurchasePriceSheetDTO : SfsBaseDataDTOBase, IHasCode, IHasName +public class PurchasePriceSheetDTO : SfsBaseDataDTOBase { - /// - /// 供应商ID + /// 价格单编码 /// - - [Display(Name = "供应商Id")] + [Display(Name = "物料代码")] [Required(ErrorMessage = "{0}是必填项")] - public Guid SupplierId { get; set; } - /// - /// 供应商名称 - /// - [Display(Name = "供应商名称")] - public string SupplierName { get; set; } + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemCode { get; set; } /// - /// 价格单编码 + /// 供应商编号 /// - [Display(Name = "代码")] + [Display(Name = "供应商编号")] [Required(ErrorMessage = "{0}是必填项")] [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Code { get; set; } + public string SupplierCode { get; set; } /// - /// 价格单名称 + /// 采购价格 /// - [Display(Name = "价格单名称")] - public string Name { get; set; } + [Display(Name = "采购价格")] + public decimal PurchasePrice { get; set; } /// /// 价格单描述 /// [Display(Name = "价格单描述")] public string Description { get; set; } - /// - /// 货币ID - /// - [Display(Name = "货币Id")] - [Required(ErrorMessage = "{0}是必填项")] - public Guid CurrencyId { get; set; } - /// - /// 货币名称 - /// - [Display(Name = "货币名称")] - public string CurrencyName { get; set; } - - //[Display(Name = "子表单")] - //public virtual List PurchasePriceDetails { get; set; } - - // } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/IPurchasePriceSheetAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/IPurchasePriceSheetAppService.cs index 47645e931..6dd5ec48e 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/IPurchasePriceSheetAppService.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/IPurchasePriceSheetAppService.cs @@ -1,6 +1,10 @@ +using System.Threading.Tasks; +using Microsoft.Extensions.Hosting; + namespace Win_in.Sfs.Basedata.Application.Contracts; public interface IPurchasePriceSheetAppService : ISfsBaseDataAppServiceBase { - + Task GetByItemCodeAsync(string itemCode,string supplierCode); + Task UpsertAsyncByInterface(PurchasePriceSheetEditInput input); } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/Inputs/PurchasePriceSheetEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/Inputs/PurchasePriceSheetEditInput.cs index 2bb715174..946fe004f 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/Inputs/PurchasePriceSheetEditInput.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/Inputs/PurchasePriceSheetEditInput.cs @@ -10,49 +10,36 @@ namespace Win_in.Sfs.Basedata.Application.Contracts; public class PurchasePriceSheetEditInput : SfsBaseDataCreateOrUpdateInputBase { #region Base - /// - /// 价格单名称 - /// - [Display(Name = "价格单名称")] - [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Name { get; set; } - /// /// 价格单描述 /// [Display(Name = "价格单描述")] - [StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] public string Description { get; set; } + #endregion - /// - /// 货币ID - /// - [Display(Name = "货币Id")] - [Required(ErrorMessage = "{0}是必填项")] - public Guid CurrencyId { get; set; } + #region Create /// - /// 是否可用 + /// 价格单编码 /// - [Display(Name = "是否可用")] + [Display(Name = "物料代码")] [Required(ErrorMessage = "{0}是必填项")] - public bool Enabled { get; set; } - #endregion + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemCode { get; set; } - #region Create /// - /// 代码 + /// 供应商编号 /// - [Display(Name = "代码")] + [Display(Name = "供应商编号")] [Required(ErrorMessage = "{0}是必填项")] [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Code { get; set; } + public string SupplierCode { get; set; } /// - /// 供应商ID + /// 采购价格 /// - [Display(Name = "供应商Id")] - [Required(ErrorMessage = "{0}是必填项")] - public Guid SupplierId { get; set; } + [Display(Name = "采购价格")] + public decimal PurchasePrice { get; set; } + #endregion } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/Inputs/PurchasePriceSheetImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/Inputs/PurchasePriceSheetImportInput.cs index 38ed8abab..3a4842ef7 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/Inputs/PurchasePriceSheetImportInput.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/PurchasePrices/Inputs/PurchasePriceSheetImportInput.cs @@ -13,51 +13,29 @@ namespace Win_in.Sfs.Basedata.Application.Contracts; public class PurchasePriceSheetImportInput : SfsBaseDataImportInputBase { - /// - /// 供应商ID - /// - - [Display(Name = "供应商Id")] - [Required(ErrorMessage = "{0}是必填项")] - - public Guid SupplierId { get; set; } - - /// - /// 供应商名称 - /// - [Display(Name = "供应商名称")] - public string SupplierName { get; set; } - /// /// 价格单编码 /// - [Display(Name = "代码")] + [Display(Name = "物料代码")] [Required(ErrorMessage = "{0}是必填项")] [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Code { get; set; } + public string ItemCode { get; set; } /// - /// 价格单名称 + /// 供应商编号 /// - [Display(Name = "价格单名称")] - public string Name { get; set; } - + [Display(Name = "供应商编号")] + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string SupplierCode { get; set; } /// /// 价格单描述 /// [Display(Name = "价格单描述")] - public string Description { get; set; } - - /// - /// 货币ID - /// - [Display(Name = "货币Id")] - [Required(ErrorMessage = "{0}是必填项")] - public Guid CurrencyId { get; set; } - + public string Description { get; set; } = "EXCLE导入"; /// - /// 货币名称 + /// 采购价格 /// - [Display(Name = "货币名称")] - public string CurrencyName { get; set; } + [Display(Name = "采购价格")] + public decimal PurchasePrice { get; set; } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/DTOs/SalePriceSheetDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/DTOs/SalePriceSheetDTO.cs index 24b4fc2c9..4df127f85 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/DTOs/SalePriceSheetDTO.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/DTOs/SalePriceSheetDTO.cs @@ -11,56 +11,82 @@ namespace Win_in.Sfs.Basedata.Application.Contracts; /// 销售价格单 /// [Display(Name = "销售价格单")] -public class SalePriceSheetDTO : SfsBaseDataDTOBase, IHasCode, IHasName +public class SalePriceSheetDTO : SfsBaseDataDTOBase { - /// - /// 客户ID + /// 物料代码 /// - [Display(Name = "客户Id")] + [Display(Name = "物料代码")] [Required(ErrorMessage = "{0}是必填项")] - - public Guid CustomerId { get; set; } - - /// - /// 客户名称 - /// - [Display(Name = "客户名称")] - public string CustomerName { get; set; } + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemCode { get; set; } /// - /// 价格单名称 + /// 客户代码 /// - [Display(Name = "价格单名称")] - public string Name { get; set; } + [Display(Name = "客户代码")] + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string CustomerCode { get; set; } /// - /// 代码 + /// 销售价格 /// - [Display(Name = "代码")] - [Required(ErrorMessage = "{0}是必填项")] - [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Code { get; set; } + [Display(Name = "销售价格")] + public decimal SalePrice { get; set; } /// /// 价格单描述 /// [Display(Name = "价格单描述")] public string Description { get; set; } + ///// + ///// 客户ID + ///// + //[Display(Name = "客户Id")] + //[Required(ErrorMessage = "{0}是必填项")] - /// - /// 货币ID - /// - [Display(Name = "货币Id")] - [Required(ErrorMessage = "{0}是必填项")] + //public Guid CustomerId { get; set; } - public Guid CurrencyId { get; set; } + ///// + ///// 客户名称 + ///// + //[Display(Name = "客户名称")] + //public string CustomerName { get; set; } - /// - /// 货币名称 - /// - [Display(Name = "货币名称")] - public string CurrencyName { get; set; } + ///// + ///// 价格单名称 + ///// + //[Display(Name = "价格单名称")] + //public string Name { get; set; } + + ///// + ///// 代码 + ///// + //[Display(Name = "代码")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Code { get; set; } + + ///// + ///// 价格单描述 + ///// + //[Display(Name = "价格单描述")] + //public string Description { get; set; } + + ///// + ///// 货币ID + ///// + //[Display(Name = "货币Id")] + //[Required(ErrorMessage = "{0}是必填项")] + + //public Guid CurrencyId { get; set; } + + ///// + ///// 货币名称 + ///// + //[Display(Name = "货币名称")] + //public string CurrencyName { get; set; } //[Display(Name = "子表单")] //public virtual List SalePriceDetails { get; set; } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/ISalePriceSheetAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/ISalePriceSheetAppService.cs index 09c869cd0..c146d6d00 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/ISalePriceSheetAppService.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/ISalePriceSheetAppService.cs @@ -1,6 +1,9 @@ +using System.Threading.Tasks; + namespace Win_in.Sfs.Basedata.Application.Contracts; public interface ISalePriceSheetAppService : ISfsBaseDataAppServiceBase { - + Task GetByItemCodeAndCustomerCode(string itemCode, string customerCode); + Task UpsertAsyncByInterface(SalePriceSheetEditInput input); } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/Inputs/SalePriceSheetEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/Inputs/SalePriceSheetEditInput.cs index 04317c807..5bacb202e 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/Inputs/SalePriceSheetEditInput.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/Inputs/SalePriceSheetEditInput.cs @@ -10,12 +10,6 @@ namespace Win_in.Sfs.Basedata.Application.Contracts; public class SalePriceSheetEditInput : SfsBaseDataCreateOrUpdateInputBase { #region Base - /// - /// 价格单名称 - /// - [Display(Name = "价格单名称")] - [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Name { get; set; } /// /// 价格单描述 @@ -25,34 +19,25 @@ public class SalePriceSheetEditInput : SfsBaseDataCreateOrUpdateInputBase public string Description { get; set; } /// - /// 货币ID + /// 物料代码 /// - [Display(Name = "货币Id")] + [Display(Name = "物料代码")] [Required(ErrorMessage = "{0}是必填项")] - public Guid CurrencyId { get; set; } - - /// - /// 是否可用 - /// - [Display(Name = "是否可用")] - [Required(ErrorMessage = "{0}是必填项")] - public bool Enabled { get; set; } - #endregion + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemCode { get; set; } - #region Create /// - /// 代码 + /// 客户代码 /// - [Display(Name = "代码")] + [Display(Name = "客户代码")] [Required(ErrorMessage = "{0}是必填项")] [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Code { get; set; } + public string CustomerCode { get; set; } /// - /// 客户ID + /// 销售价格 /// - [Display(Name = "客户Id")] - [Required(ErrorMessage = "{0}是必填项")] - public Guid CustomerId { get; set; } + [Display(Name = "销售价格")] + public decimal SalePrice { get; set; } #endregion } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/Inputs/SalePriceSheetImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/Inputs/SalePriceSheetImportInput.cs index 17965badd..82dcadb6b 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/Inputs/SalePriceSheetImportInput.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SalePrices/Inputs/SalePriceSheetImportInput.cs @@ -13,48 +13,31 @@ namespace Win_in.Sfs.Basedata.Application.Contracts; public class SalePriceSheetImportInput : SfsBaseDataImportInputBase { /// - /// 客户ID - /// - [Display(Name = "客户Id")] - [Required(ErrorMessage = "{0}是必填项")] - public Guid CustomerId { get; set; } - - /// - /// 客户名称 - /// - [Display(Name = "客户名称")] - public string CustomerName { get; set; } - - /// - /// 价格单名称 + /// 价格单描述 /// - [Display(Name = "价格单名称")] - public string Name { get; set; } + [Display(Name = "价格单描述")] + [StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string Description { get; set; } /// - /// 代码 + /// 物料代码 /// - [Display(Name = "代码")] + [Display(Name = "物料代码")] [Required(ErrorMessage = "{0}是必填项")] [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Code { get; set; } - - /// - /// 价格单描述 - /// - [Display(Name = "价格单描述")] - public string Description { get; set; } + public string ItemCode { get; set; } /// - /// 货币ID + /// 客户代码 /// - [Display(Name = "货币Id")] + [Display(Name = "客户代码")] [Required(ErrorMessage = "{0}是必填项")] - public Guid CurrencyId { get; set; } + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string CustomerCode { get; set; } /// - /// 货币名称 + /// 销售价格 /// - [Display(Name = "货币名称")] - public string CurrencyName { get; set; } + [Display(Name = "销售价格")] + public decimal SalePrice { get; set; } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Commons/SplitPacking_UpdateDetailInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Commons/SplitPacking_UpdateDetailInput.cs new file mode 100644 index 000000000..765da4cfd --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Commons/SplitPacking_UpdateDetailInput.cs @@ -0,0 +1,43 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Basedata.SplitPackings.Commons; +public class SplitPacking_UpdateDetailInput +{ + /// + /// 主表number + /// + [Required(ErrorMessage = "{0}是必填项")] + public string Number { get; set; } + /// + /// 子表from标签 + /// + [Required(ErrorMessage = "{0}是必填项")] + public string FromPackingCode { get; set; } + /// + /// from数量 + /// + [Required(ErrorMessage = "{0}是必填项")] + [Range(1, 99999, ErrorMessage = "{0}值范围在1至99999之间")] + public decimal FromQty { get; set; } + /// + /// 子表的to标签 + /// + [Required(ErrorMessage = "{0}是必填项")] + public string ToPackingCode { get; set; } + /// + /// to数量 + /// + [Required(ErrorMessage = "{0}是必填项")] + [Range(1, 99999, ErrorMessage = "{0}值范围在1至99999之间")] + public decimal ToQty { get; set; } + + public string FromLocationCode { get; set; } + + public string ToLocationCode { get; set; } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Dtos/SplitPackingRecDto.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Dtos/SplitPackingRecDto.cs new file mode 100644 index 000000000..c0d83cfb7 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Dtos/SplitPackingRecDto.cs @@ -0,0 +1,160 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public class SplitPackingRecDTO : SfsBaseDataDTOBase +{ + /// + /// 操作类型 + /// + [Display(Name = "操作类型")] + public OprTypeEnum OprType { get; set; } + + /// + /// 源箱码 + /// + [Display(Name = "源箱码")] + public string FromPackingCode { get; set; } + + /// + /// 源顶级箱码 + /// + [Display(Name = "源顶级箱码")] + public string FromTopPackingCode { get; set; } + + /// + /// 源标包数量 + /// + [Display(Name = "源标包数量")] + public decimal FromStdPackQty { get; set; } + + /// + /// 源计量单位 + /// + [Display(Name = "源计量单位")] + public string FromUom { get; set; } + + /// + /// 源数量 + /// + [Display(Name = "源数量")] + public decimal FromQty { get; set; } + + /// + /// 目标箱码 + /// + [Display(Name = "目标箱码")] + public string ToPackingCode { get; set; } + + /// + /// 目标顶级箱码 + /// + [Display(Name = "目标顶级箱码")] + public string ToTopPackingCode { get; set; } + + /// + /// 目标标包数量 + /// + [Display(Name = "目标标包数量")] + public decimal ToStdPackQty { get; set; } + + /// + /// 目标计量单位 + /// + [Display(Name = "目标计量单位")] + public string ToUom { get; set; } + + /// + /// 目标数量 + /// + [Display(Name = "目标数量")] + public decimal ToQty { get; set; } + + /// + /// 物料号 + /// + [Display(Name = "物料号")] + public string ItemCode { get; set; } + + /// + /// 物料名称 + /// + [Display(Name = "物料名称")] + public string ItemName { get; set; } + + /// + /// 物料描述1 + /// + [Display(Name = "物料描述1")] + public string ItemDesc1 { get; set; } + + /// + /// 物料描述2 + /// + [Display(Name = "物料描述2")] + public string ItemDesc2 { get; set; } + + /// + /// 源批次 + /// + [Display(Name = "源批次")] + public string FromLot { get; set; } + + /// + /// 目标批次 + /// + [Display(Name = "目标批次")] + public string ToLot { get; set; } + + /// + /// 采购订单 + /// + [Display(Name = "采购订单")] + public string PurchaseInfo_PoNumber { get; set; } + + /// + /// 供应商发货单 + /// + [Display(Name = "供应商发货单")] + public string PurchaseInfo_AsnNumber { get; set; } + + /// + /// 到货通知 + /// + [Display(Name = "到货通知")] + public string ArrivalNoticNumber { get; set; } + + /// + /// 任务单 + /// + [Display(Name = "任务单")] + public string TaskOrderNumber { get; set; } + + /// + /// 收货记录单 + /// + [Display(Name = "收货记录单")] + public string ReceiptRecNumber { get; set; } + + /// + /// 上架单 + /// + [Display(Name = "上架单")] + public string PutOnShelfNumber { get; set; } + + /// + /// 标签类型 + /// + [Display(Name = "标签类型")] + public EnumLabelType LabelType { get; set; } + +} + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/ISplitPackingRecAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/ISplitPackingRecAppService.cs new file mode 100644 index 000000000..b36056209 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/ISplitPackingRecAppService.cs @@ -0,0 +1,30 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Shared.Application.Contracts; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public interface ISplitPackingRecAppService + : ISfsBaseDataAppServiceBase +{ + Task BatchInsertAsync(List inputs); + + /// + /// 取每个目标箱码的最后一条拆箱记录 + /// + /// 目标箱码列表 + /// + Task> GetListByToPackingCode(List toPackingCodeList); + + /// + /// 取每个源标箱码的“操作状态=其它”的拆箱记录 + /// + /// 源标箱码列表 + /// + Task> GetListByFromPackingCode(List fromPackingCodeList); + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Inputs/SplitPackingRecEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Inputs/SplitPackingRecEditInput.cs new file mode 100644 index 000000000..595d7a362 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Inputs/SplitPackingRecEditInput.cs @@ -0,0 +1,162 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + + +public class SplitPackingRecEditInput : SfsBaseDataCreateOrUpdateInputBase +{ + /// + /// 操作类型 + /// + [Required(ErrorMessage = "{0}是必填项")] + public OprTypeEnum OprType { get; set; } + + /// + /// 源箱码 + /// + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string FromPackingCode { get; set; } + + /// + /// 源顶级箱码 + /// + //public string FromTopPackingCode { get; set; } + + /// + /// 源标包数量 + /// + [Required(ErrorMessage = "{0}是必填项")] + public decimal FromStdPackQty { get; set; } + + /// + /// 源计量单位 + /// + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string FromUom { get; set; } + + /// + /// 源数量 + /// + [Required(ErrorMessage = "{0}是必填项")] + public decimal FromQty { get; set; } + + /// + /// 目标箱码 + /// + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ToPackingCode { get; set; } + + /// + /// 目标顶级箱码 + /// + //public string ToTopPackingCode { get; set; } + + /// + /// 目标标包数量 + /// + [Required(ErrorMessage = "{0}是必填项")] + public decimal ToStdPackQty { get; set; } + + /// + /// 目标计量单位 + /// + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ToUom { get; set; } + + /// + /// 目标数量 + /// + [Required(ErrorMessage = "{0}是必填项")] + public decimal ToQty { get; set; } + + /// + /// 物料号 + /// + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemCode { get; set; } + + /// + /// 物料名称 + /// + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemName { get; set; } + + /// + /// 物料描述1 + /// + [StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemDesc1 { get; set; } + + /// + /// 物料描述2 + /// + [StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemDesc2 { get; set; } + + /// + /// 源批次 + /// + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string FromLot { get; set; } + + /// + /// 目标批次 + /// + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ToLot { get; set; } + + /// + /// 采购订单 + /// + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string PurchaseInfo_PoNumber { get; set; } + + /// + /// 供应商发货单 + /// + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string PurchaseInfo_AsnNumber { get; set; } + + /// + /// 到货通知 + /// + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ArrivalNoticNumber { get; set; } + + /// + /// 任务单 + /// + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string TaskOrderNumber { get; set; } + + /// + /// 收货记录单 + /// + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ReceiptRecNumber { get; set; } + + /// + /// 上架单 + /// + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string PutOnShelfNumber { get; set; } + + /// + /// 标签类型 + /// + public EnumLabelType LabelType { get; set; } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Inputs/SplitPackingRecImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Inputs/SplitPackingRecImportInput.cs new file mode 100644 index 000000000..ca7f851f0 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/Inputs/SplitPackingRecImportInput.cs @@ -0,0 +1,14 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + + +[Display(Name = "拆箱记录")] +public class SplitPackingRecImportInput : SfsBaseDataImportInputBase +{ +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/SplitPackingRecPermissions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/SplitPackingRecPermissions.cs new file mode 100644 index 000000000..7d51981ad --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/SplitPackings/SplitPackingRecPermissions.cs @@ -0,0 +1,20 @@ +using Volo.Abp.Authorization.Permissions; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application.Contracts; + +public static class SplitPackingRecPermissions +{ + public const string Default = BasedataPermissions.GroupName + "." + nameof(SplitPackingRec); + public const string Create = Default + "." + BasedataPermissions.CreateStr; + public const string Update = Default + "." + BasedataPermissions.UpdateStr; + public const string Delete = Default + "." + BasedataPermissions.DeleteStr; + + public static void AddSplitPackingRecPermission(this PermissionGroupDefinition permissionGroup) + { + var SplitPackingRecPermission = permissionGroup.AddPermission(Default, BasedataPermissionDefinitionProvider.L(nameof(SplitPackingRec))); + SplitPackingRecPermission.AddChild(Create, BasedataPermissionDefinitionProvider.L(BasedataPermissions.CreateStr)); + SplitPackingRecPermission.AddChild(Update, BasedataPermissionDefinitionProvider.L(BasedataPermissions.UpdateStr)); + SplitPackingRecPermission.AddChild(Delete, BasedataPermissionDefinitionProvider.L(BasedataPermissions.DeleteStr)); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/DTOs/StdCostPriceSheetDTO.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/DTOs/StdCostPriceSheetDTO.cs index b253237bb..fa1cafb39 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/DTOs/StdCostPriceSheetDTO.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/DTOs/StdCostPriceSheetDTO.cs @@ -8,51 +8,71 @@ namespace Win_in.Sfs.Basedata.Application.Contracts; /// 标准成本价格单 /// [Display(Name = "标准成本价格单")] -public class StdCostPriceSheetDTO : SfsBaseDataDTOBase, IHasCode, IHasName +public class StdCostPriceSheetDTO : SfsBaseDataDTOBase { /// - /// 供应商Id + /// 价格单编码 /// - [Display(Name = "供应商Id")] + [Display(Name = "物料代码")] [Required(ErrorMessage = "{0}是必填项")] - public Guid SupplierId { get; set; } - /// - /// 供应商名称 - /// - [Display(Name = "供应商名称")] - [Required(ErrorMessage = "{0}是必填项")] - public string SupplierName { get; set; } - /// - /// 价格单名称 - /// - [Display(Name = "价格单名称")] - [Required(ErrorMessage = "{0}是必填项")] - [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Name { get; set; } + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemCode { get; set; } + /// - /// 代码 + /// 标准成本价格 /// - [Display(Name = "代码")] - [Required(ErrorMessage = "{0}是必填项")] - [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Code { get; set; } + [Display(Name = "标准成本价格")] + public decimal StdCostPrice { get; set; } + /// /// 价格单描述 /// [Display(Name = "价格单描述")] - [StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] public string Description { get; set; } - /// - /// 货币Id - /// - [Display(Name = "货币Id")] - [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] - public Guid CurrencyId { get; set; } - /// - /// 货币名称 - /// - [Display(Name = "货币名称")] - [Required(ErrorMessage = "{0}是必填项")] - public string CurrencyName { get; set; } + + ///// + ///// 供应商Id + ///// + //[Display(Name = "供应商Id")] + //[Required(ErrorMessage = "{0}是必填项")] + //public Guid SupplierId { get; set; } + ///// + ///// 供应商名称 + ///// + //[Display(Name = "供应商名称")] + //[Required(ErrorMessage = "{0}是必填项")] + //public string SupplierName { get; set; } + ///// + ///// 价格单名称 + ///// + //[Display(Name = "价格单名称")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Name { get; set; } + ///// + ///// 代码 + ///// + //[Display(Name = "代码")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Code { get; set; } + ///// + ///// 价格单描述 + ///// + //[Display(Name = "价格单描述")] + //[StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public string Description { get; set; } + ///// + ///// 货币Id + ///// + //[Display(Name = "货币Id")] + //[StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + //public Guid CurrencyId { get; set; } + ///// + ///// 货币名称 + ///// + //[Display(Name = "货币名称")] + //[Required(ErrorMessage = "{0}是必填项")] + //public string CurrencyName { get; set; } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/IStdCostPriceSheetAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/IStdCostPriceSheetAppService.cs index 882a246b6..5304021e9 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/IStdCostPriceSheetAppService.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/IStdCostPriceSheetAppService.cs @@ -1,5 +1,10 @@ +using System.Threading.Tasks; +using Win_in.Sfs.Basedata.Domain; + namespace Win_in.Sfs.Basedata.Application.Contracts; public interface IStdCostPriceSheetAppService : ISfsBaseDataAppServiceBase { + Task GetByItemCode(string itemCode); + Task UpsertAsyncByInterface(StdCostPriceSheetEditInput input); } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/Inputs/StdCostPriceSheetEditInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/Inputs/StdCostPriceSheetEditInput.cs index 3f8a460bb..8e6ff07ef 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/Inputs/StdCostPriceSheetEditInput.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/Inputs/StdCostPriceSheetEditInput.cs @@ -10,13 +10,6 @@ namespace Win_in.Sfs.Basedata.Application.Contracts; public class StdCostPriceSheetEditInput : SfsBaseDataCreateOrUpdateInputBase { #region Base - /// - /// 价格单名称 - /// - [Display(Name = "价格单名称")] - [Required(ErrorMessage = "{0}是必填项")] - [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Name { get; set; } /// /// 价格单描述 @@ -26,33 +19,19 @@ public class StdCostPriceSheetEditInput : SfsBaseDataCreateOrUpdateInputBase public string Description { get; set; } /// - /// 货币ID - /// - [Display(Name = "货币Id")] - public Guid CurrencyId { get; set; } - - /// - /// 是否可用 + /// 标准成本价格 /// - [Display(Name = "是否可用")] - [Required(ErrorMessage = "{0}是必填项")] - public bool Enabled { get; set; } + [Display(Name = "销售价格")] + public decimal StdCostPrice { get; set; } #endregion #region Create /// - /// 代码 + /// 物料代码 /// - [Display(Name = "代码")] + [Display(Name = "物料代码")] [Required(ErrorMessage = "{0}是必填项")] [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Code { get; set; } - - /// - /// 供应商ID - /// - [Display(Name = "供应商Id")] - [Required(ErrorMessage = "{0}是必填项")] - public Guid SupplierId { get; set; } + public string ItemCode { get; set; } #endregion } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/Inputs/StdCostPriceSheetImportInput.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/Inputs/StdCostPriceSheetImportInput.cs index 6e4c33b6f..8538b47bb 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/Inputs/StdCostPriceSheetImportInput.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/StdCostPrices/Inputs/StdCostPriceSheetImportInput.cs @@ -9,36 +9,6 @@ namespace Win_in.Sfs.Basedata.Application.Contracts; /// public class StdCostPriceSheetImportInput : SfsBaseDataImportInputBase { - /// - /// 供应商Id - /// - [Display(Name = "供应商Id")] - [Required(ErrorMessage = "{0}是必填项")] - public Guid SupplierId { get; set; } - - /// - /// 供应商名称 - /// - [Display(Name = "供应商名称")] - [Required(ErrorMessage = "{0}是必填项")] - public string SupplierName { get; set; } - - /// - /// 价格单名称 - /// - [Display(Name = "价格单名称")] - [Required(ErrorMessage = "{0}是必填项")] - [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Name { get; set; } - - /// - /// 代码 - /// - [Display(Name = "代码")] - [Required(ErrorMessage = "{0}是必填项")] - [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] - public string Code { get; set; } - /// /// 价格单描述 /// @@ -47,17 +17,17 @@ public class StdCostPriceSheetImportInput : SfsBaseDataImportInputBase public string Description { get; set; } /// - /// 货币Id + /// 标准成本价格 /// - [Display(Name = "货币Id")] - [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] - public Guid CurrencyId { get; set; } + [Display(Name = "销售价格")] + public decimal StdCostPrice { get; set; } /// - /// 货币名称 + /// 物料代码 /// - [Display(Name = "货币名称")] + [Display(Name = "物料代码")] [Required(ErrorMessage = "{0}是必填项")] - public string CurrencyName { get; set; } + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ItemCode { get; set; } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Win_in.Sfs.Basedata.Application.Contracts.csproj b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Win_in.Sfs.Basedata.Application.Contracts.csproj index 0fe7d3a1e..84d9de372 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Win_in.Sfs.Basedata.Application.Contracts.csproj +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application.Contracts/Win_in.Sfs.Basedata.Application.Contracts.csproj @@ -1,4 +1,4 @@ - + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/BasedataAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/BasedataAppService.cs index 6e97e78ba..aba20e875 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/BasedataAppService.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/BasedataAppService.cs @@ -9,5 +9,6 @@ public abstract class BasedataAppService : ApplicationService { LocalizationResource = typeof(BasedataResource); ObjectMapperContext = typeof(BasedataApplicationModule); + } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/BasedataApplicationAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/BasedataApplicationAutoMapperProfile.cs index 6ed3caf50..c5301da0f 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/BasedataApplicationAutoMapperProfile.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/BasedataApplicationAutoMapperProfile.cs @@ -12,6 +12,7 @@ public partial class BasedataApplicationAutoMapperProfile : Profile CalendarAutoMapperProfile(); InterfaceCalendarAutoMapperProfile(); CategoryAutoMapperProfile(); + PositionCodeAutoMapperProfile(); CurrencyAutoMapperProfile(); CurrencyExchangeAutoMapperProfile(); CustomerAddressAutoMapperProfile(); @@ -48,5 +49,13 @@ public partial class BasedataApplicationAutoMapperProfile : Profile WorkStationAutoMapperProfile(); WorkGroupAutoMapperProfile(); WorkShopAutoMapperProfile(); + EquipmentAutoMapperProfile(); + SplitPackingRecAutoMapperProfile(); + KittingAutoMapperProfile(); + EquipmentLocAutoMapperProfile(); + EquipmentPartCodeAutoMapperProfile(); + EquipmentLocCapAutoMapperProfile(); + + } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Boms/BomAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Boms/BomAppService.cs index 47cce0cf7..ec2e12831 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Boms/BomAppService.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Boms/BomAppService.cs @@ -182,4 +182,20 @@ public class BomAppService : await base.CheckProductAsync(importInput.Product, validationRresult).ConfigureAwait(false); await base.CheckComponentAndComponentQtyAsync(importInput.Component, importInput.ComponentQty, validationRresult).ConfigureAwait(false); } + + /// + /// 根据总成号、总成数量取所有子物料及其汇总数量 + /// + /// 总成号 + /// 总成数量 + /// + [HttpGet("get-material-total-qty")] + public virtual async Task> GetMaterialTotalQtyAsync(string productCode, int productNum) + { + var entities = await _bomManager.GetMaterialTotalQtyAsync(productCode, productNum).ConfigureAwait(false); + return ObjectMapper.Map, List>(entities); + + } + + } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAppService.cs new file mode 100644 index 000000000..be46cb4df --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAppService.cs @@ -0,0 +1,84 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.IO; +using System.Linq; +using System.Linq.Expressions; +using System.Threading; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Http; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp; +using Volo.Abp.Application.Dtos; +using Volo.Abp.Caching; +using Volo.Abp.Domain.Repositories; +using Volo.Abp.Validation; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Application.Contracts.ExportAndImport; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application; + +[Authorize] +[Route($"{BasedataConsts.RootPath}Equipment")] +public class EquipmentAppService + : SfsBaseDataWithCodeAppServiceBase + , IEquipmentAppService +{ + private readonly IEquipmentManager _manager; + private new readonly IEquipmentRepository _repository; + private readonly IExportImportService _importService; + public EquipmentAppService( + IEquipmentRepository repository, + IDistributedCache cache, + IExportImportService importService, + IEquipmentManager manager) + : base(repository, cache) + { + _importService=importService; + _repository = repository; + _manager = manager; + base.CreatePolicyName = EquipmentPermissions.Create; + base.UpdatePolicyName = EquipmentPermissions.Update; + base.DeletePolicyName = EquipmentPermissions.Delete; + } + + [HttpPost("check")] + //[Authorize(ErpLocationPermissions.Default)] + public virtual async Task CheckAsync(string code, EquipmentCheckInput input) + { + await Task.CompletedTask.ConfigureAwait(false); + } + [HttpPost("upsert")] + + public virtual async Task UpsertAsync(EquipmentEditInput input) + { + var entity = ObjectMapper.Map(input); + await _repository.UpsertAsync(entity).ConfigureAwait(false); + } + + [HttpPost] + [Route("")] + public override async Task CreateAsync(EquipmentEditInput input) + { + var first= _repository.WithDetails().FirstOrDefault(p => p.Code == input.Code); + if (first == null) + { + var entity = ObjectMapper.Map(input); + entity.Code = string.Format("{0}{1}", "Q", entity.Code); + await _repository.UpsertAsync(entity).ConfigureAwait(false); + var entity1=_repository.WithDetails().FirstOrDefault(p => p.Code == input.Code); + return ObjectMapper.Map(entity1); + } + else + { + throw new UserFriendlyException($"已存在器具编号{input.Code}!"); + } + + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAreaAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAreaAppService.cs new file mode 100644 index 000000000..4774d50fe --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAreaAppService.cs @@ -0,0 +1,85 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Linq.Expressions; +using System.Threading; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp; +using Volo.Abp.Application.Dtos; +using Volo.Abp.Caching; +using Volo.Abp.Domain.Repositories; +using Volo.Abp.ObjectMapping; +using Volo.Abp.Validation; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application; + +[Authorize] +[Route($"{BasedataConsts.RootPath}EquipmentArea")] +public class EquipmentAreaAppService + : SfsBaseDataWithCodeAppServiceBase + , IEquipmentAreaAppService +{ + private readonly IEquipmentAreaManager _manager; + private new readonly IEquipmentAreaRepository _repository; + private new readonly IEquipmentRepository _eRepository; + + public EquipmentAreaAppService( + IEquipmentAreaRepository repository, + IEquipmentRepository eRepository, + IDistributedCache cache, + IEquipmentAreaManager manager) + : base(repository, cache) + { + _repository = repository; + _eRepository = eRepository; + _manager = manager; + base.CreatePolicyName = EquipmentPermissions.Create; + base.UpdatePolicyName = EquipmentPermissions.Update; + base.DeletePolicyName = EquipmentPermissions.Delete; + } + + [HttpPost("check")] + //[Authorize(ErpLocationPermissions.Default)] + + public virtual async Task CheckAsync(string code, EquipmentAreaCheckInput input) + { + //var result = new AbpValidationResult(); + //if (Repository.GetDbSet().Where(p => p.Code == code).Any()) + //{ + // result.Errors.Add(new ValidationResult($"存在编码为{code}的器具!")); + //} + //if (result.Errors.Count > 0) + //{ + // throw new AbpValidationException(result.Errors); + //} + await Task.CompletedTask.ConfigureAwait(false); + } + + + + [HttpPost("upsert")] + + public virtual async Task UpsertAsync(EquipmentAreaEditInput input) + { + var entity = ObjectMapper.Map(input); + await _repository.UpsertAsync(entity).ConfigureAwait(false); + } + protected override async Task ValidateImportModelAsync(EquipmentAreaImportInput importInput, List validationRresult) + { + + await base.ValidateImportModelAsync(importInput, validationRresult).ConfigureAwait(false); + //await base.CheckEquipmentAsync(importInput.Code, validationRresult).ConfigureAwait(false); + } + + + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAreaAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAreaAutoMapperProfile.cs new file mode 100644 index 000000000..459e6dacd --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAreaAutoMapperProfile.cs @@ -0,0 +1,33 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application; + +public partial class BasedataApplicationAutoMapperProfile : Profile +{ + private void EquipmentAreaAutoMapperProfile() + { + CreateMap() + + .ReverseMap(); + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.TenantId) + .Ignore(x => x.Remark) + .Ignore(x => x.ExtraProperties) + .Ignore(x => x.ConcurrencyStamp); + + + //CreateMap() + + //CreateMap() + // .Ignore(x => x.ItemCategory) + // .Ignore(x => x.Color); + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.ConcurrencyStamp).Ignore(x => x.Id); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAutoMapperProfile.cs new file mode 100644 index 000000000..a21be096e --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentAutoMapperProfile.cs @@ -0,0 +1,33 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application; + +public partial class BasedataApplicationAutoMapperProfile : Profile +{ + private void EquipmentAutoMapperProfile() + { + CreateMap() + + .ReverseMap(); + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.TenantId) + .Ignore(x => x.Remark) + .Ignore(x => x.ExtraProperties) + .Ignore(x => x.ConcurrencyStamp) + .ForMember(p => p.Code, p => p.MapFrom(q => "Q" + q.Code)); + + //CreateMap() + + //CreateMap() + // .Ignore(x => x.ItemCategory) + // .Ignore(x => x.Color); + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.ConcurrencyStamp).Ignore(x => x.Id); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocAppService.cs new file mode 100644 index 000000000..14ad08e9e --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocAppService.cs @@ -0,0 +1,115 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.IO; +using System.Linq; +using System.Linq.Expressions; +using System.Threading; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Http; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp; +using Volo.Abp.Application.Dtos; +using Volo.Abp.Caching; +using Volo.Abp.Domain.Repositories; +using Volo.Abp.Validation; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Application.Contracts.ExportAndImport; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application; + +[Authorize] +[Route($"{BasedataConsts.RootPath}EquipmentLoc")] +public class EquipmentLocAppService + : SfsBaseDataWithCodeAppServiceBase + , IEquipmentLocAppService +{ + + private readonly IEquipmentLocManager _manager; + private new readonly IEquipmentLocRepository _repository; + private new readonly ILocationAppService _locRepository; + + private readonly IExportImportService _importService; + + public EquipmentLocAppService( + IEquipmentLocRepository repository, + IDistributedCache cache, + IExportImportService importService, + ILocationAppService locRepository, + IEquipmentLocManager manager) + : base(repository, cache) + { + _importService=importService; + _repository = repository; + _manager = manager; + _locRepository= locRepository; + base.CreatePolicyName = EquipmentPermissions.Create; + base.UpdatePolicyName = EquipmentPermissions.Update; + base.DeletePolicyName = EquipmentPermissions.Delete; + } + + [HttpPost("check")] + //[Authorize(ErpLocationPermissions.Default)] + + public virtual async Task CheckAsync(string code, EquipmentLocCheckInput input) + { + await Task.CompletedTask.ConfigureAwait(false); + } + + [HttpPost("upsert")] + + public virtual async Task UpsertAsync(EquipmentLocEditInput input) + { + var entity = ObjectMapper.Map(input); + await _repository.UpsertAsync(entity).ConfigureAwait(false); + } + [HttpPost] + [Route("")] + public override async Task CreateAsync(EquipmentLocEditInput input) + { + var first= _repository.WithDetails().FirstOrDefault(p => p.Code == input.Code && p.LocCode==input.LocCode); + if (first == null) + { + var entity = ObjectMapper.Map(input); + await _repository.UpsertAsync(entity).ConfigureAwait(false); + var entity1=_repository.WithDetails().FirstOrDefault(p => p.Code == input.Code && p.LocCode == input.LocCode); + return ObjectMapper.Map(entity1); + } + else + { + throw new UserFriendlyException($"已存在器具代码{input.Code}和库位{input.LocCode}关系!"); + } + } + [HttpPost] + [Route("GetEquipmentLocs")] + public async Task> GetEquipmentLocAsync(List p_ls) + { + var query=await _repository.GetQueryableAsync().ConfigureAwait(false); + var list =query.Where(p => p_ls.Contains(p.Code)); + return ObjectMapper.Map< List ,List>(list.ToList()); + } + [HttpGet] + [Route("GetLocs")] + public async Task> GetLocsAsync() + { + var query = await _repository.GetQueryableAsync().ConfigureAwait(false); + var list = query.Select(p => p.LocCode).Distinct().ToList(); + return list; + } + + protected override async Task ValidateImportModelAsync(EquipmentLocImportInput importInput, List validationRresult) + { + await base.CheckItemBasicItemCodeAsync(importInput.Code, validationRresult).ConfigureAwait(false); + await base.CheckRawLocationAsync(importInput.LocCode, validationRresult).ConfigureAwait(false); + //await base.CheckComponentAndComponentQtyAsync(importInput.Component, importInput.ComponentQty, validationRresult).ConfigureAwait(false); + } + + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocAutoMapperProfile.cs new file mode 100644 index 000000000..a7754a6ed --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocAutoMapperProfile.cs @@ -0,0 +1,34 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application; + +public partial class BasedataApplicationAutoMapperProfile : Profile +{ + private void EquipmentLocAutoMapperProfile() + { + CreateMap() + + .ReverseMap(); + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.TenantId) + .Ignore(x => x.Remark) + .Ignore(x => x.ExtraProperties) + .Ignore(x => x.ConcurrencyStamp) + .Ignore(x=>x.State) + .ForMember(p =>p.Code, p => p.MapFrom(q =>q.Code)) ; + + //CreateMap() + + //CreateMap() + // .Ignore(x => x.ItemCategory) + // .Ignore(x => x.Color); + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.ConcurrencyStamp).Ignore(x => x.Id); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocCapAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocCapAppService.cs new file mode 100644 index 000000000..8b1e527b9 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocCapAppService.cs @@ -0,0 +1,70 @@ +using System.Linq; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp; +using Volo.Abp.Caching; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Application.Contracts.ExportAndImport; +namespace Win_in.Sfs.Basedata.Application; + +[Authorize] +[Route($"{BasedataConsts.RootPath}EquipmentLocCap")] +public class EquipmentLocCapAppService + : SfsBaseDataWithCodeAppServiceBase + , IEquipmentLocCapAppService +{ + private readonly IEquipmentLocCapManager _manager; + private new readonly IEquipmentLocCapRepository _repository; + private readonly IExportImportService _importService; + public EquipmentLocCapAppService( + IEquipmentLocCapRepository repository, + IDistributedCache cache, + IExportImportService importService, + IEquipmentLocCapManager manager) + : base(repository, cache) + { + _importService=importService; + _repository = repository; + _manager = manager; + base.CreatePolicyName = EquipmentPermissions.Create; + base.UpdatePolicyName = EquipmentPermissions.Update; + base.DeletePolicyName = EquipmentPermissions.Delete; + } + + [HttpPost("check")] + //[Authorize(ErpLocationPermissions.Default)] + public virtual async Task CheckAsync(string code, EquipmentLocCapCheckInput input) + { + await Task.CompletedTask.ConfigureAwait(false); + } + [HttpPost("upsert")] + + public virtual async Task UpsertAsync(EquipmentLocCapEditInput input) + { + var entity = ObjectMapper.Map(input); + await _repository.UpsertAsync(entity).ConfigureAwait(false); + } + + [HttpPost] + [Route("")] + public override async Task CreateAsync(EquipmentLocCapEditInput input) + { + var query =await _repository.GetQueryableAsync().ConfigureAwait(false); + var first=query.FirstOrDefault(p => p.Code == input.Code); + if (first == null) + { + var entity = ObjectMapper.Map(input); + entity.Code = string.Format("{0}{1}", "Q", entity.Code); + await _repository.UpsertAsync(entity).ConfigureAwait(false); + var entity1=_repository.WithDetails().FirstOrDefault(p => p.Code == input.Code); + return ObjectMapper.Map(entity1); + } + else + { + throw new UserFriendlyException($"已存在器具编号{input.Code}!"); + } + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocCapAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocCapAutoMapperProfile.cs new file mode 100644 index 000000000..fd94d51bb --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentLocCapAutoMapperProfile.cs @@ -0,0 +1,43 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application; + +public partial class BasedataApplicationAutoMapperProfile : Profile +{ + private void EquipmentLocCapAutoMapperProfile() + { + CreateMap() + .IgnoreAuditedObjectProperties() + + .ReverseMap(); + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.TenantId) + .Ignore(x => x.Remark) + .Ignore(x => x.ExtraProperties) + .Ignore(x => x.ConcurrencyStamp) + .Ignore(x => x.StdQty) + .Ignore(x => x.PartCode) + .Ignore(x => x.Qty) + .Ignore(x => x.ConcurrencyStamp) + + + .ForMember(p => p.Code, p => p.MapFrom(q =>q.Code)); + + //CreateMap() + + //CreateMap() + // .Ignore(x => x.ItemCategory) + // .Ignore(x => x.Color); + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.StdQty) + .Ignore(x => x.PartCode) + .Ignore(x => x.Qty) + .Ignore(x => x.ConcurrencyStamp).Ignore(x => x.Id); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentPartCodeAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentPartCodeAppService.cs new file mode 100644 index 000000000..5a9bf75b8 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentPartCodeAppService.cs @@ -0,0 +1,109 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.IO; +using System.Linq; +using System.Linq.Expressions; +using System.Threading; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Http; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp; +using Volo.Abp.Application.Dtos; +using Volo.Abp.Caching; +using Volo.Abp.Domain.Repositories; +using Volo.Abp.ObjectMapping; +using Volo.Abp.Validation; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Application.Contracts.ExportAndImport; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application; + +[Authorize] +[Route($"{BasedataConsts.RootPath}EquipmentPartCode")] +public class EquipmentPartCodeAppService + : SfsBaseDataWithCodeAppServiceBase + , IEquipmentPartCodeAppService +{ + private readonly IEquipmentPartCodeManager _manager; + private new readonly IEquipmentPartCodeRepository _repository; + private readonly IExportImportService _importService; + + public EquipmentPartCodeAppService( + IEquipmentPartCodeRepository repository, + IDistributedCache cache, + IExportImportService importService, + + IEquipmentPartCodeManager manager) + : base(repository, cache) + { + _importService=importService; + _repository = repository; + _manager = manager; + base.CreatePolicyName = EquipmentPermissions.Create; + base.UpdatePolicyName = EquipmentPermissions.Update; + base.DeletePolicyName = EquipmentPermissions.Delete; + } + + [HttpPost("check")] + //[Authorize(ErpLocationPermissions.Default)] + + public virtual async Task CheckAsync(string code, EquipmentPartCodeCheckInput input) + { + await Task.CompletedTask.ConfigureAwait(false); + } + + [HttpPost("upsert")] + + public virtual async Task UpsertAsync(EquipmentPartCodeEditInput input) + { + var entity = ObjectMapper.Map(input); + + await _repository.UpsertAsync(entity).ConfigureAwait(false); + } + + [HttpPost] + [Route("")] + public override async Task CreateAsync(EquipmentPartCodeEditInput input) + { + var first= _repository.WithDetails().FirstOrDefault(p => p.Code == input.Code && p.PartCode==input.PartCode); + if (first == null) + { + var entity = ObjectMapper.Map(input); + + await _repository.UpsertAsync(entity).ConfigureAwait(false); + var entity1=_repository.WithDetails().FirstOrDefault(p => p.Code == input.Code && p.PartCode == input.PartCode); + return ObjectMapper.Map(entity1); + } + else + { + throw new UserFriendlyException($"已存在器具代码{input.Code}和零件代码{input.PartCode}关系!"); + } + } + [HttpPost] + [Route("GetEquipmentPartCodes")] + public async Task> GetEquipmentPartCodesAsync(List p_ls) + { + var query = await _repository.GetQueryableAsync().ConfigureAwait(false); + var list = query.Where(p => p_ls.Contains(p.Code)); + + return ObjectMapper.Map, List>(list.ToList()); + + } + protected override async Task ValidateImportModelAsync(EquipmentPartCodeImportInput importInput, List validationRresult) + { + await base.CheckItemBasicItemCodeAsync(importInput.Code, validationRresult).ConfigureAwait(false); + + //await base.CheckComponentAndComponentQtyAsync(importInput.Component, importInput.ComponentQty, validationRresult).ConfigureAwait(false); + } + + + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentPartCodeAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentPartCodeAutoMapperProfile.cs new file mode 100644 index 000000000..c89a35201 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Equipments/EquipmentPartCodeAutoMapperProfile.cs @@ -0,0 +1,35 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application; + +public partial class BasedataApplicationAutoMapperProfile : Profile +{ + private void EquipmentPartCodeAutoMapperProfile() + { + CreateMap() + + .ReverseMap(); + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.TenantId) + .Ignore(x => x.Remark) + .Ignore(x => x.ExtraProperties) + .Ignore(x => x.ConcurrencyStamp) + .ForMember(p =>p.Code, p => p.MapFrom(q =>q.Code)) + + ; + + //CreateMap() + + //CreateMap() + // .Ignore(x => x.ItemCategory) + // .Ignore(x => x.Color); + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.ConcurrencyStamp).Ignore(x => x.Id); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Kittings/KittingAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Kittings/KittingAppService.cs new file mode 100644 index 000000000..f2f376764 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Kittings/KittingAppService.cs @@ -0,0 +1,350 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.IO; +using System.Linq; +using System.Threading.Tasks; +using EFCore.BulkExtensions; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Http; +using Microsoft.AspNetCore.Mvc; +using Microsoft.EntityFrameworkCore; +using NUglify.Helpers; +using Omu.ValueInjecter; +using Volo.Abp; +using Volo.Abp.Caching; +using Volo.Abp.Domain.Entities; +using Volo.Abp.Domain.Repositories; +using Volo.Abp.ObjectMapping; +using Volo.Abp.Uow; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Basedata.Kittings.Inputs; +using Win_in.Sfs.Shared; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Application.Contracts.ExportAndImport; + + +namespace Win_in.Sfs.Basedata.Application; + +[Authorize] +[Route($"{BasedataConsts.RootPath}kitting")] + +public class KittingAppService : SfsBaseDataWithCodeAppServiceBase, IKittingAppService +{ + private new readonly IKittingRepository _repository; + + private readonly IExportImportService _excelService; + + private readonly IKittingManager _manager; + + public KittingAppService(IKittingRepository repository, IDistributedCache cache, IKittingManager manager, IExportImportService excelService) : base(repository,cache) + { + _repository = repository; + _manager = manager; + _excelService = excelService; + //base.CreatePolicyName = KittingPermissions.Create; + //base.UpdatePolicyName = KittingPermissions.Update; + //base.DeletePolicyName = KittingPermissions.Delete; + } + [HttpPost] + [Route("")] + public override async Task CreateAsync(KittingEditInput input) + { + + var detailquery=await _repository.WithDetailsAsync().ConfigureAwait(false); + var first = detailquery.FirstOrDefault(p => p.Code == input.Code); + var codes = input.Details.Select(p => p.PartCode); + if (first != null) + { + + throw new UserFriendlyException($"已存在编码:{input.Code}的Kitting箱"); + //var query = from itm in input.Details + // join itm1 in first.Details on itm.PartCode equals itm1.PartCode + // into temp1 + // from tm1 in temp1.DefaultIfEmpty() + // where tm1 == null + // select itm; + //var details = ObjectMapper.Map, List>(query.ToList()); + //foreach (var itm in details) + //{ + // itm.SetId(GuidGenerator.Create()); + // itm.MasterId = first.Id; + // first.AddDetails(itm); + //} + //var entity= await _repository.UpdateAsync(first).ConfigureAwait(false); + //return ObjectMapper.Map(entity); + } + else + { + var entity = ObjectMapper.Map(input); + entity.SetId(Guid.NewGuid()); + entity.Details.ForEach(item => + { + item.MasterId = entity.Id; + }); + entity = await _repository.InsertAsync(entity).ConfigureAwait(false); + return ObjectMapper.Map(entity); + + } + + //first.Details.Where(p => codes.Contains(p.PartCode)); + //var entity = ObjectMapper.Map(input); + //entity.SetId(Guid.NewGuid()); + //entity.Details.ForEach(item => + //{ + // item.MasterId = entity.Id; + //}); + //entity = await _repository.InsertAsync(entity).ConfigureAwait(false); + //return ObjectMapper.Map(entity); + } + + [HttpPut] + [Route("{id}")] + public override Task UpdateAsync(Guid id, KittingEditInput input) + { + //var detailquery = _repository.WithDetails(); + //var first = detailquery.FirstOrDefault(p => p.Id == id); + //var ids=input.Details.Select(p => p.Id); + //first.Details.Where(p =>ids.Contains(p.Id)); + + return base.UpdateAsync(id, input); + + //var entity = ObjectMapper.Map(input); + ////entity.SetId(id); + ////entity.Code = first.Code; + //await _repository.UpsertAsync(entity).ConfigureAwait(false); + //var firstEntity = detailquery.FirstOrDefault(p => p.Id == id); + //return ObjectMapper.Map(first); + + + } + + [HttpPost("update")] + public virtual async Task UpdateAsync(KittingEditInput input) + { + var entity = ObjectMapper.Map(input); + //var dic=await _repository.GetAsync(r => r.Code == entity.Code); + // if (dic != null) + // { + // await _repository.DeleteAsync(dic); + // } + // await _repository.InsertAsync(entity); + await _repository.UpdateAsync(entity).ConfigureAwait(false); + } + + + [HttpPost("upsert")] + public virtual async Task UpsertAsync(KittingEditInput input) + { + var entity = ObjectMapper.Map(input); + await _repository.UpsertAsync(entity).ConfigureAwait(false); + } + [HttpPost("import")] + [Consumes("multipart/form-data")] + + public override async Task ImportAsync([FromForm] SfsImportRequestInput requestInput, [Required] IFormFile file) + { + var query= _repository.WithDetails().AsNoTracking(); + using var ms = new MemoryStream(); + await file.OpenReadStream().CopyToAsync(ms).ConfigureAwait(false); + var inputFileBytes = ms.GetAllBytes(); + var importList= _excelService.Import(inputFileBytes).ToList(); + var checklist=importList.GroupBy(p => new { p.Code, p.PartCode }).Where(g => g.Count() > 1).Select(p => new { Code = p.Key.Code, PartCode = p.Key.PartCode });//导入重复报错 //检测是否导入重复 + List errors = new List(); + if (checklist.Any()) + { + + foreach (var error in checklist) { + + errors.Add(new KittingErrorDto() { Code=error.Code,PartCode=error.PartCode, Content="记录有重复!" }); + } + } + var codeList=importList.Select(p=>p.Code).Distinct().ToList(); + var includeList = query.Where(p => codeList.Contains(p.Code)).ToList(); + var existCodeList = includeList.Select(p => p.Code).ToList(); + var newCodeList = from itm in codeList + join itm1 in existCodeList on itm equals itm1 + into temp + from tm in temp.DefaultIfEmpty() + where tm == null + select itm; + if(newCodeList.Any()) + { + #region 新KITTING + var newKittingList = importList.Where(p => newCodeList.Contains(p.Code)).ToList();//新Kitting + List newKittingInputList = new List(); + List newMainList = new List(); + List newdetailList = new List(); + foreach (var itm in newCodeList) + { + var newDetail = newKittingList.Where(p => p.Code == itm).ToList(); + var first = newDetail.FirstOrDefault(); + var kitting = new KittingEditInput(); + kitting.InjectFrom(first); + // kitting.Code = $"Q{kitting.Code}"; + foreach (var detail in newDetail) + { + var inputdetail = new KittingDetailInput(); + inputdetail.InjectFrom(detail); + kitting.Details.Add(inputdetail); + } + newKittingInputList.Add(kitting); + } + var kittingList = ObjectMapper.Map, List>(newKittingInputList); + foreach (var itm in kittingList) + { + var id = Guid.NewGuid(); + itm.SetId(id); + //newMainList.Add(itm); + foreach (var detail in itm.Details) + { + detail.SetId(Guid.NewGuid()); + detail.MasterId = id; + //newdetailList.Add(detail); + } + } + await _repository.InsertManyAsync(kittingList).ConfigureAwait(false); + + //await _repository.GetDbContext().BulkInsertAsync(newMainList).ConfigureAwait(false); + //await _repository.GetDbContext().BulkInsertAsync(newdetailList).ConfigureAwait(false); + #endregion + } + if (existCodeList.Any()) + { + var existKittingList = importList.Where(p => existCodeList.Contains(p.Code)).ToList();//新Kitting + List existKittingInputList = new List(); + //List existKittingDetailList = new List(); + //List newKittingDetailList = new List(); + foreach (var include in includeList) + { + var newDetail = existKittingList.Where(p => p.Code == include.Code).ToList(); + var innerExist = from itm in newDetail + join itm1 in include.Details on itm.PartCode equals itm1.PartCode + select itm; + if (innerExist.Any()) + { + var list = innerExist.ToList(); + foreach (var itm in include.Details) + { + var entity = list.FirstOrDefault(p => p.PartCode == itm.PartCode); + itm.Desc1 = entity.Desc1; + itm.Desc2 = entity.Desc2; + itm.Qty = entity.Qty; + itm.Conf = entity.Conf; + //existKittingDetailList.Add(itm); + } + } + var leftExist = from itm in newDetail + join itm1 in include.Details on itm.PartCode equals itm1.PartCode + into temp + from tm in temp.DefaultIfEmpty() + where tm == null + select itm; + if (leftExist.Any()) + { + var list = leftExist.ToList(); + foreach (var itm in list) + { + var detail = new KittingDetail(); + detail.InjectFrom(itm); + detail.SetId(Guid.NewGuid()); + detail.MasterId = include.Id; + } + } + + //var entity = new KittingEditInput(); + //entity.InjectFrom(include); + + //foreach (var detail in include.Details) + //{ + // var detailInput = new KittingDetailInput(); + // detailInput.InjectFrom(detail); + // entity.Details.Add(detailInput); + + //} + + //var newDetail = existKittingList.Where(p => p.Code == entity.Code).ToList(); + //var innerExist = from itm in newDetail + // join itm1 in entity.Details on itm.PartCode equals itm1.PartCode + // select itm; + //if (innerExist.Any()) + //{ + // var list = innerExist.ToList(); + // foreach (var itm in entity.Details) + // { + // var l = list.FirstOrDefault(p => p.PartCode == itm.PartCode); + // itm.Desc1 = l.Desc1; + // itm.Desc2 = l.Desc2; + // itm.Qty = l.Qty; + // itm.Conf = l.Conf; + // } + //} + //var leftExist = from itm in newDetail + // join itm1 in entity.Details on itm.PartCode equals itm1.PartCode + // into temp + // from tm in temp.DefaultIfEmpty() + // where tm == null + // select itm; + //if (leftExist.Any()) + //{ + // var list = leftExist.ToList(); + // foreach (var itm in list) + // { + // var detail = new KittingDetailInput(); + // detail.InjectFrom(itm); + // detail.Id = Guid.NewGuid(); + // detail.MasterId = entity.Id; + // entity.Details.Add(detail); + // } + //} + //existKittingInputList.Add(entity); + } + // List list1 = new List(); + // foreach (var itm in existKittingInputList) + // { + // Kitting kitting = new Kitting(); + // kitting.InjectFrom(itm); + // kitting.SetId(itm.Id); + // foreach (var detail in itm.Details) + // { + // KittingDetail kittingDetail = new KittingDetail(); + // kittingDetail.InjectFrom(detail); + // kittingDetail.SetId(detail.Id); + // kitting.AddDetails(kittingDetail); + // } + // list1.Add(kitting); + // } + //var details= list1.Select(p => p.Details).ToList(); + // //await _repository.GetDbContext().BulkInsertAsync(newKittingDetailList).ConfigureAwait(continueOnCapturedContext: false); + // //await _repository.GetDbContext().BulkUpdateAsync(existKittingDetailList).ConfigureAwait(continueOnCapturedContext: false); + // // var ls= ObjectMapper.Map< List ,List >(existKittingInputList); + // //await _repository.UpdateManyAsync(list1,true).ConfigureAwait(continueOnCapturedContext: false); + // await _manager.ImportDataAsync(includeList).ConfigureAwait(false); + } + + if (errors.Count > 0) + { + var fileContent= _excelService.Export(errors); + return new TestResult(fileContent.FileContents, ExportImportService.ContentType) { FileDownloadName="错误信息" }; + } + + var fileContent1 = _excelService.Export(importList); + new TestResult(fileContent1.FileContents, ExportImportService.ContentType) { FileDownloadName = "导入文件" }; + return new JsonResult(new { Code = 200, FileDownloadName="" }); + } + + + + protected override async Task GetFromRepositoryAsync(string code) + { + var displayName = typeof(KittingDTO).GetNameOfDisplay(); + + var query = await _repository.WithDetailsAsync().ConfigureAwait(false); + + var entity = await query.Where(p => p.Code == code).FirstOrDefaultAsync().ConfigureAwait(false); + + return ObjectMapper.Map(entity); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Kittings/KittingAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Kittings/KittingAutoMapperProfile.cs new file mode 100644 index 000000000..657c97e5a --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Kittings/KittingAutoMapperProfile.cs @@ -0,0 +1,116 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Kittings.Inputs; + +namespace Win_in.Sfs.Basedata.Application; + +public partial class BasedataApplicationAutoMapperProfile : Profile +{ + private void KittingAutoMapperProfile() + { + CreateMap() + .ReverseMap(); + + CreateMap() + .ReverseMap(); + + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.Details) + .Ignore(x => x.TenantId) + .Ignore(x => x.ExtraProperties) + .Ignore(x => x.Remark) + .Ignore(x => x.ConcurrencyStamp) + .Ignore(x => x.Id); + + + CreateMap() + .IgnoreAuditedObjectProperties() + //.ForMember(x => x., y => y.MapFrom(t => t.Code)) + .ForMember(x => x.PartCode, y => y.MapFrom(t => t.PartCode)) + .ForMember(x => x.Desc1, y => y.MapFrom(t => t.Desc1)) + .ForMember(x => x.Desc2, y => y.MapFrom(t => t.Desc2)) + .Ignore(x => x.MasterId) + .Ignore(x => x.TenantId) + .Ignore(x => x.Remark) + .Ignore(x => x.Id); + + + + + + + + + // CreateMap() + // .IgnoreAuditedObjectProperties() + // .Ignore(x => x.Items) + // .Ignore(x => x.TenantId) + // .Ignore(x => x.ExtraProperties) + // .Ignore(x => x.Remark) + // .Ignore(x => x.ConcurrencyStamp) + // .Ignore(x => x.Id); + + //CreateMap() + // .IgnoreAuditedObjectProperties() + + // .Ignore(x => x.MasterId) + // .Ignore(x => x.Enabled) + // .Ignore(x => x.TenantId) + // .Ignore(x => x.Remark) + // .Ignore(x => x.Id); + + CreateMap() + .IgnoreAuditedObjectProperties(); + // .ForMember(x => x.MasterId, y => y.MapFrom(t => t.MasterId)) + + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.ConcurrencyStamp) + .Ignore(x => x.Id); + } + + + //CreateMap() + // ; + + // CreateMap() + // ; + + // CreateMap() + // .IgnoreAuditedObjectProperties() + // .Ignore(x => x.Items) + // .Ignore(x => x.TenantId) + // .Ignore(x => x.ExtraProperties) + // .Ignore(x => x.Remark) + // .Ignore(x => x.ConcurrencyStamp) + // .Ignore(x => x.Id); + + //CreateMap() + // .IgnoreAuditedObjectProperties() + // .ForMember(x => x.Code, y => y.MapFrom(t => t.Item_Code)) + // .ForMember(x => x.Name, y => y.MapFrom(t => t.Item_Name)) + // .ForMember(x => x.Description, y => y.MapFrom(t => t.Item_Description)) + // .ForMember(x => x.Value, y => y.MapFrom(t => t.Item_Value)) + // .Ignore(x => x.MasterId) + // .Ignore(x => x.Enabled) + // .Ignore(x => x.TenantId) + // .Ignore(x => x.Remark) + // .Ignore(x => x.Id); + + //CreateMap() + // .IgnoreAuditedObjectProperties() + // ; + + //CreateMap() + // .IgnoreAuditedObjectProperties() + // .Ignore(x => x.ConcurrencyStamp) + //.Ignore(x => x.Id); + + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PositionCode/PositionCodeAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PositionCode/PositionCodeAppService.cs new file mode 100644 index 000000000..043d22231 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PositionCode/PositionCodeAppService.cs @@ -0,0 +1,204 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Threading.Tasks; +using DocumentFormat.OpenXml.Vml.Office; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; +using Microsoft.EntityFrameworkCore; +using Volo.Abp; +using Volo.Abp.Caching; +using Volo.Abp.Domain.Entities; +using Volo.Abp.Domain.Repositories; +using Volo.Abp.ObjectMapping; +using Volo.Abp.Uow; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application; + +[Authorize] +[Route($"{BasedataConsts.RootPath}position-code")] + +public class PositionCodeAppService + : SfsBaseDataWithCodeAppServiceBase + , IPositionCodeAppService +{ + private readonly IPositionCodeManager _manager; + + private new readonly IPositionCodeRepository _repository; + + + public PositionCodeAppService(IPositionCodeRepository repository, + IDistributedCache cache, IPositionCodeManager manager) : base(repository, cache) + { + base.CreatePolicyName = CategoryPermissions.Create; + base.UpdatePolicyName = CategoryPermissions.Update; + base.DeletePolicyName = CategoryPermissions.Delete; + _manager = manager; + _repository = repository; + + } + + /// + /// 用来重写 新增实体 + /// + /// + /// + /// + [HttpPost("")] + [UnitOfWork] + public override async Task CreateAsync(PositionCodeEditInput input) + { + var existEntity = await GetByCodeAsync(input.Code).ConfigureAwait(false); + if (existEntity != null) + { + throw new UserFriendlyException($"{input.Code} 已存在"); + } + + var itemEntity = await _repository.FirstOrDefaultAsync(p => p.PartCode == input.PartCode).ConfigureAwait(false); + if(itemEntity != null) + { + throw new UserFriendlyException($"{input.PartCode} 物品已存在"); + } + + var itemBasic = await ItemBasicAppService.GetByCodeAsync(input.PartCode).ConfigureAwait(false); + Check.NotNull(itemBasic, "物品代码", $"物品 {input.PartCode} 不存在"); + //如果类型选择为原料,校验物料号类型必须为原料,器具、KItting 的不用加校验 + if (input.Type == EnumRecommendType.W && itemBasic.Type != "10C02") + { + throw new UserFriendlyException($"{input.PartCode} 物料号类型必须为原料"); + } + input.PartName = itemBasic.Name; + input.PartDesc = itemBasic.Desc1; + input.BasicUom = itemBasic.BasicUom; + input.StdPackQty = itemBasic.StdPackQty; + + var location = await LocationAppService.GetByCodeAsync(input.LocationCode).ConfigureAwait(false); + Check.NotNull(location, "库位代码", $"库位 {input.LocationCode} 不存在"); + //如果类型选择为原料,库位的类型必须为原料库位 + if (input.Type == EnumRecommendType.W && location.Type != EnumLocationType.RAW) + { + throw new UserFriendlyException($"{input.LocationCode} 库位的类型必须为原料库位"); + } + input.LocationName = location.Name; + + if(input.Type== EnumRecommendType.None) + { + throw new UserFriendlyException($"{input.Type} 位置码类型不正确"); + } + + return await base.CreateAsync(input).ConfigureAwait(false); + } + + /// + /// 用来重写 更新实体 + /// + /// + /// + /// + /// + [HttpPut] + [Route("{id}")] + public override async Task UpdateAsync(Guid id, PositionCodeEditInput input) + { + var entity = await _repository.GetAsync(id).ConfigureAwait(false); + if (entity == null) + { + throw new UserFriendlyException($"{id} 未找到位置码信息"); + } + var itemEntity = await _repository.FirstOrDefaultAsync(p => p.PartCode == input.PartCode && p.Code!=input.Code).ConfigureAwait(false); + if (itemEntity != null) + { + throw new UserFriendlyException($"{input.PartCode} 物品已存在"); + } + + + var itemBasic = await ItemBasicAppService.GetByCodeAsync(input.PartCode).ConfigureAwait(false); + Check.NotNull(itemBasic, "物品代码", $"物品 {input.PartCode} 不存在"); + //如果类型选择为原料,校验物料号类型必须为原料,器具、KItting 的不用加校验 + if (input.Type == EnumRecommendType.W && itemBasic.Type != "10C02") + { + throw new UserFriendlyException($"{input.PartCode} 物料号类型必须为原料"); + } + entity.PartName = itemBasic.Name; + entity.PartDesc = itemBasic.Desc1; + entity.BasicUom = itemBasic.BasicUom; + entity.StdPackQty = itemBasic.StdPackQty; + + var location = await LocationAppService.GetByCodeAsync(input.LocationCode).ConfigureAwait(false); + Check.NotNull(location, "库位代码", $"库位 {input.LocationCode} 不存在"); + //如果类型选择为原料,库位的类型必须为原料库位 + if (input.Type == EnumRecommendType.W && location.Type!= EnumLocationType.RAW) + { + throw new UserFriendlyException($"{input.LocationCode} 库位的类型必须为原料库位"); + } + entity.LocationName = location.Name; + + await _repository.UpdateAsync(entity).ConfigureAwait(false); + var dto = ObjectMapper.Map(entity); + + return dto; + + } + + /// + /// 用来重写 导入数据时可以加工数据 + /// + /// + /// + protected override async Task> ImportProcessingEntityAsync( + Dictionary dictionary) + { + var addList = dictionary.Where(p => p.Value == EntityState.Added).Select(p => p.Key); + + foreach (var positionCode in addList) + { + var itemBasic = await ItemBasicAppService.GetByCodeAsync(positionCode.PartCode).ConfigureAwait(false); + positionCode.PartName = itemBasic.Name; + positionCode.PartDesc = itemBasic.Desc1; + positionCode.BasicUom = itemBasic.BasicUom; + positionCode.StdPackQty = itemBasic.StdPackQty; + positionCode.Code = positionCode.Type + positionCode.Code; + positionCode.CreatorId= CurrentUser.Id; + var location = await LocationAppService.GetByCodeAsync(positionCode.LocationCode).ConfigureAwait(false); + positionCode.LocationName = location.Name; + } + + return dictionary; + } + + private async Task CheckPositionCodeInputAsync(PositionCodeImportInput input, List validationRresult) + { + var itemEntity = await _repository.FirstOrDefaultAsync(p => p.PartCode == input.PartCode && p.Code != input.Code).ConfigureAwait(false); + if (itemEntity != null) + { + validationRresult.Add(new ValidationResult($"物品代码{input.PartCode}已存在", new string[] { "物品代码" })); + } + var itemBasic = await ItemBasicAppService.GetByCodeAsync(input.PartCode).ConfigureAwait(false); + //如果类型选择为原料,校验物料号类型必须为原料,器具、KItting 的不用加校验 + if (input.Type == EnumRecommendType.W && itemBasic.Type != "10C02") + { + validationRresult.Add(new ValidationResult($"物品代码{input.PartCode} 物料号类型必须为原料", new string[] { "物料号类型" })); + } + var location = await LocationAppService.GetByCodeAsync(input.LocationCode).ConfigureAwait(false); + //如果类型选择为原料,库位的类型必须为原料库位 + if (input.Type==EnumRecommendType.W && location.Type != EnumLocationType.RAW) + { + validationRresult.Add(new ValidationResult($"库位代码{input.LocationCode} 库位的类型必须为原料库位", new string[] { "库位类型" })); + } + } + + protected override async Task ValidateImportModelAsync(PositionCodeImportInput importInput, List validationRresult) + { + await base.ValidateImportModelAsync(importInput, validationRresult).ConfigureAwait(false); + await CheckPositionCodeInputAsync(importInput, validationRresult).ConfigureAwait(false); + await base.CheckItemBasicItemCodeAsync(importInput.PartCode, validationRresult).ConfigureAwait(false); + await base.CheckRawLocationAsync(importInput.LocationCode, validationRresult).ConfigureAwait(false); + + } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PositionCode/PositionCodeAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PositionCode/PositionCodeAutoMapperProfile.cs new file mode 100644 index 000000000..b069821b0 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PositionCode/PositionCodeAutoMapperProfile.cs @@ -0,0 +1,28 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application; + +public partial class BasedataApplicationAutoMapperProfile : Profile +{ + private void PositionCodeAutoMapperProfile() + { + CreateMap() + .ReverseMap(); + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.TenantId) + .Ignore(x => x.Remark) + .Ignore(x => x.ExtraProperties) + .Ignore(x => x.ConcurrencyStamp) + ; + + CreateMap() + .Ignore(x => x.ReportStatus) + .Ignore(x => x.ReportReason); + + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PurchasePrices/PurchasePriceSheetAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PurchasePrices/PurchasePriceSheetAppService.cs index 279a697c4..8f75e08fe 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PurchasePrices/PurchasePriceSheetAppService.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PurchasePrices/PurchasePriceSheetAppService.cs @@ -1,3 +1,4 @@ +using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Volo.Abp.Caching; @@ -12,12 +13,32 @@ namespace Win_in.Sfs.Basedata.Application; public class PurchasePriceSheetAppService : SfsBaseDataAppServiceBase, IPurchasePriceSheetAppService { - + private readonly IPurchasePriceSheetRepository _repository; public PurchasePriceSheetAppService(IPurchasePriceSheetRepository repository, IDistributedCache cache) : base(repository, cache) { - + _repository = repository; base.CreatePolicyName = PurchasePriceSheetPermissions.Create; base.UpdatePolicyName = PurchasePriceSheetPermissions.Update; base.DeletePolicyName = PurchasePriceSheetPermissions.Delete; } + /// + /// 根据供应零件号查询 + /// + /// + /// + /// + [HttpGet("by-item-code")] + public virtual async Task GetByItemCodeAsync(string itemCode,string supplierCode) + { + var entity = await _repository.FindAsync(p => p.ItemCode== itemCode&&p.SupplierCode== supplierCode).ConfigureAwait(false); + var dto = ObjectMapper.Map(entity); + return dto; + } + [HttpPost("upsert-interface")] + + public virtual async Task UpsertAsyncByInterface(PurchasePriceSheetEditInput input) + { + var entity = ObjectMapper.Map(input); + await _repository.UpsertAsyncByInterface(entity).ConfigureAwait(false); + } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PurchasePrices/PurchasePriceSheetAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PurchasePrices/PurchasePriceSheetAutoMapperProfile.cs index 8643b7752..10326b686 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PurchasePrices/PurchasePriceSheetAutoMapperProfile.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/PurchasePrices/PurchasePriceSheetAutoMapperProfile.cs @@ -10,8 +10,6 @@ public partial class BasedataApplicationAutoMapperProfile : Profile private void PurchasePriceSheetAutoMapperProfile() { CreateMap() - .Ignore(x => x.SupplierName) - .Ignore(x => x.CurrencyName) .ReverseMap(); } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SalePrices/SalePriceSheetAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SalePrices/SalePriceSheetAppService.cs index 4ad4c1311..e44928e0e 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SalePrices/SalePriceSheetAppService.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SalePrices/SalePriceSheetAppService.cs @@ -1,6 +1,8 @@ +using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Volo.Abp.Caching; +using Volo.Abp.Domain.Entities; using Win_in.Sfs.Basedata.Application.Contracts; using Win_in.Sfs.Basedata.Domain; using Win_in.Sfs.Basedata.Domain.Shared; @@ -12,12 +14,28 @@ namespace Win_in.Sfs.Basedata.Application; public class SalePriceSheetAppService : SfsBaseDataAppServiceBase, ISalePriceSheetAppService { - + private readonly ISalePriceSheetRepository _repository; public SalePriceSheetAppService(ISalePriceSheetRepository repository, IDistributedCache cache) : base(repository, cache) { base.CreatePolicyName = SalePriceSheetPermissions.Create; base.UpdatePolicyName = SalePriceSheetPermissions.Update; base.DeletePolicyName = SalePriceSheetPermissions.Delete; + _repository = repository; + } + + [HttpPost("upsert-interface")] + + public virtual async Task UpsertAsyncByInterface(SalePriceSheetEditInput input) + { + var entity = ObjectMapper.Map(input); + await _repository.UpsertAsyncByInterface(entity).ConfigureAwait(false); + } + [HttpPut("get-by-itemcode-and-customercode")] + public virtual async Task GetByItemCodeAndCustomerCode(string itemCode,string customerCode) + { + var entity = await _repository.FindAsync(p => p.ItemCode == itemCode&&p.CustomerCode== customerCode).ConfigureAwait(false); + var dto = ObjectMapper.Map(entity); + return dto; } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SalePrices/SalePriceSheetAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SalePrices/SalePriceSheetAutoMapperProfile.cs index 87ec4f112..840a4f415 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SalePrices/SalePriceSheetAutoMapperProfile.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SalePrices/SalePriceSheetAutoMapperProfile.cs @@ -10,8 +10,6 @@ public partial class BasedataApplicationAutoMapperProfile : Profile private void SalePriceSheetAutoMapperProfile() { CreateMap() - .Ignore(x => x.CustomerName) - .Ignore(x => x.CurrencyName) .ReverseMap(); } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SplitPackings/SplitPackingRecAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SplitPackings/SplitPackingRecAppService.cs new file mode 100644 index 000000000..fc87385c9 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SplitPackings/SplitPackingRecAppService.cs @@ -0,0 +1,69 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp.Caching; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Basedata.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Application; + +/// +/// 拆箱记录 +/// +[Authorize] +[Route($"{BasedataConsts.RootPath}split-packing-rec")] +public class SplitPackingRecAppService : + SfsBaseDataAppServiceBase + , ISplitPackingRecAppService +{ + private readonly ISplitPackingRecManager _splitPackingRecManager; + + public SplitPackingRecAppService(ISplitPackingRecRepository repository + ,ISplitPackingRecManager splitPackingRecManager + ,IDistributedCache cache + ) : base(repository, cache) + { + base.CreatePolicyName = StdCostPriceSheetPermissions.Create; + base.UpdatePolicyName = StdCostPriceSheetPermissions.Update; + base.DeletePolicyName = StdCostPriceSheetPermissions.Delete; + _splitPackingRecManager = splitPackingRecManager; + } + [HttpPost("batch-insert")] + public async Task BatchInsertAsync(List inputs) + { + List lst = ObjectMapper.Map, List>(inputs); + bool ret = await _splitPackingRecManager.BatchInsertAsync(lst).ConfigureAwait(false); + return ret; + } + + /// + /// 取每个目标箱码的最后一条拆箱记录 + /// + /// 目标箱码列表 + /// + [HttpGet("by-to-packing-code")] + public async Task> GetListByToPackingCode(List toPackingCodeList) + { + var lst = await _splitPackingRecManager.GetListByToPackingCode(toPackingCodeList).ConfigureAwait(false); + List ret = ObjectMapper.Map, List>(lst); + return ret; + } + + /// + /// 取每个源标箱码的“操作状态=其它”的拆箱记录 + /// + /// 源标箱码列表 + /// + [HttpGet("by-from-packing-code")] + public async Task> GetListByFromPackingCode(List fromPackingCodeList) + { + var lst = await _splitPackingRecManager.GetListByFromPackingCode(fromPackingCodeList).ConfigureAwait(false); + List ret = ObjectMapper.Map, List>(lst); + return ret; + } + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SplitPackings/SplitPackingRecAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SplitPackings/SplitPackingRecAutoMapperProfile.cs new file mode 100644 index 000000000..dc89749ef --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/SplitPackings/SplitPackingRecAutoMapperProfile.cs @@ -0,0 +1,23 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.Application; + +public partial class BasedataApplicationAutoMapperProfile : Profile +{ + private void SplitPackingRecAutoMapperProfile() + { + CreateMap(); + CreateMap() + .Ignore(t => t.FromTopPackingCode) + .Ignore(t => t.ToTopPackingCode) + .Ignore(t => t.LastModificationTime) + .Ignore(t => t.LastModifierId) + .Ignore(t => t.CreationTime) + .Ignore(t => t.CreatorId) + .Ignore(t => t.ConcurrencyStamp) + .Ignore(t => t.Id); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/StdCostPrices/StdCostPriceSheetAppService.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/StdCostPrices/StdCostPriceSheetAppService.cs index 62900ef38..5090b0f26 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/StdCostPrices/StdCostPriceSheetAppService.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/StdCostPrices/StdCostPriceSheetAppService.cs @@ -1,6 +1,8 @@ +using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Volo.Abp.Caching; +using Volo.Abp.Domain.Entities; using Win_in.Sfs.Basedata.Application.Contracts; using Win_in.Sfs.Basedata.Domain; using Win_in.Sfs.Basedata.Domain.Shared; @@ -12,12 +14,29 @@ namespace Win_in.Sfs.Basedata.Application; public class StdCostPriceSheetAppService : SfsBaseDataAppServiceBase, IStdCostPriceSheetAppService { - + private readonly IStdCostPriceSheetRepository _repository; public StdCostPriceSheetAppService(IStdCostPriceSheetRepository repository, IDistributedCache cache) : base(repository, cache) { base.CreatePolicyName = StdCostPriceSheetPermissions.Create; base.UpdatePolicyName = StdCostPriceSheetPermissions.Update; base.DeletePolicyName = StdCostPriceSheetPermissions.Delete; + _repository = repository; + } + + [HttpPost("upsert-interface")] + + public virtual async Task UpsertAsyncByInterface(StdCostPriceSheetEditInput input) + { + var entity = ObjectMapper.Map(input); + await _repository.UpsertAsyncByInterface(entity).ConfigureAwait(false); + } + + [HttpPut("get-by-itemcode")] + public virtual async Task GetByItemCode(string itemCode) + { + var entity = await _repository.FindAsync(p => p.ItemCode == itemCode).ConfigureAwait(false); + var dto = ObjectMapper.Map(entity); + return dto; } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/StdCostPrices/StdCostPriceSheetAutoMapperProfile.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/StdCostPrices/StdCostPriceSheetAutoMapperProfile.cs index b02916e6c..f99988470 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/StdCostPrices/StdCostPriceSheetAutoMapperProfile.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/StdCostPrices/StdCostPriceSheetAutoMapperProfile.cs @@ -10,8 +10,6 @@ public partial class BasedataApplicationAutoMapperProfile : Profile private void StdCostPriceSheetAutoMapperProfile() { CreateMap() - .Ignore(x => x.SupplierName) - .Ignore(x => x.CurrencyName) .ReverseMap(); } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Win_in.Sfs.Basedata.Application.csproj b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Win_in.Sfs.Basedata.Application.csproj index 6cb51991c..6f33022f8 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Win_in.Sfs.Basedata.Application.csproj +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Application/Win_in.Sfs.Basedata.Application.csproj @@ -1,4 +1,4 @@ - + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/Commons/CommonHelper.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/Commons/CommonHelper.cs new file mode 100644 index 000000000..1859b5324 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/Commons/CommonHelper.cs @@ -0,0 +1,31 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Newtonsoft.Json; + +namespace Win_in.Sfs.Basedata.Domain.Shared; +public sealed class CommonHelper +{ + /// + /// 克隆对象 + /// + /// + /// + /// + public static T CloneObj(T sourceObj) + { + string json = JsonConvert.SerializeObject(sourceObj); + var ret = JsonConvert.DeserializeObject(json); + return ret; + } + + public static DateTime CurTime + { + get + { + return DateTime.Now; + } + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/Commons/ExtMethod.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/Commons/ExtMethod.cs new file mode 100644 index 000000000..c2d021ad4 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/Commons/ExtMethod.cs @@ -0,0 +1,368 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.Linq; +using System.Reflection; +using System.Text; + +namespace Win_in.Sfs.Basedata.Domain.Shared; +public static class ExtMethod +{ + #region string + public static int? TryToInt(this string p_str) + { + int resu; + bool isSucc = int.TryParse(p_str, out resu); + if (isSucc) + { + return resu; + } + else + { + return null; + } + } + + public static int TryToIntZero(this string p_str) + { + return p_str.TryToInt() ?? 0; + } + + + public static double? TryToDouble(this string p_str) + { + double resu; + bool isSucc = double.TryParse(p_str, out resu); + if (isSucc) + { + return resu; + } + else + { + return null; + } + } + + public static double TryToDoubleZero(this string p_str) + { + return p_str.TryToDouble() ?? 0; + } + + public static DateTime? TryToDateTime(this string p_str) + { + if (p_str == null) + { + return null; + } + string str = p_str?.ToString(); + DateTime resu; + bool isSucc = DateTime.TryParse(str, out resu); + if (isSucc) + { + return resu; + } + else + { + return null; + } + } + + public static bool? TryToBool(this string p_str) + { + if (p_str == null) + { + return null; + } + bool ret; + bool isSucc = Boolean.TryParse(p_str, out ret); + if (isSucc) + { + return ret; + } + else + { + return null; + } + + } + + public static decimal? TryToDecimal(this string p_str) + { + if (p_str == null) + { + return null; + } + decimal ret; + bool isSucc = Decimal.TryParse(p_str, out ret); + if (isSucc) + { + return ret; + } + else + { + return null; + } + } + + public static decimal TryToDecimalZero(this string p_str) + { + return p_str.TryToDecimal() ?? 0.0M; + } + + #endregion + + #region object + public static int? TryToInt(this object p_obj) + { + if (p_obj == null) + { + return null; + } + string str = p_obj?.ToString(); + int resu; + bool isSucc = int.TryParse(str, out resu); + if (isSucc) + { + return resu; + } + else + { + return null; + } + } + + public static int TryToIntZero(this object p_obj) + { + int? ret = TryToInt(p_obj); + return ret ?? 0; + } + + public static double? TryToDouble(this object p_obj) + { + if (p_obj == null) + { + return null; + } + string str = p_obj?.ToString(); + double resu; + bool isSucc = double.TryParse(str, out resu); + if (isSucc) + { + return resu; + } + else + { + return null; + } + } + + public static double TryToDoubleZero(this object p_obj) + { + return p_obj.TryToDouble() ?? 0; + } + + public static DateTime? TryToDateTime(this object p_obj) + { + if (p_obj == null) + { + return null; + } + string str = p_obj?.ToString(); + DateTime resu; + bool isSucc = DateTime.TryParse(str, out resu); + if (isSucc) + { + return resu; + } + else + { + return null; + } + } + + public static DateTime TryToDateTime1900(this object p_obj) + { + var ret = p_obj.TryToDateTime() ?? Convert.ToDateTime("1900-01-01"); + return ret; + } + public static bool? TryToBool(this object p_obj) + { + if (p_obj == null) + { + return null; + } + string str = p_obj?.ToString(); + bool resu; + bool isSucc = Boolean.TryParse(str, out resu); + if (isSucc) + { + return resu; + } + else + { + return null; + } + } + + public static decimal? TryToDecimal(this object p_obj) + { + if (p_obj == null) + { + return null; + } + string str = p_obj?.ToString(); + decimal ret; + bool isSucc = Decimal.TryParse(str, out ret); + if (isSucc) + { + return ret; + } + else + { + return null; + } + } + + public static decimal TryToDecimalZero(this object p_obj) + { + return p_obj.TryToDecimal() ?? 0.0M; + } + #endregion + + public static bool HasValue(this string p_str) + { + return string.IsNullOrEmpty(p_str?.Trim()) ? false : true; + } + + public static bool IsNullOrEmpty2(this string p_str) + { + return string.IsNullOrEmpty(p_str?.Trim()) ? true : false; + } + + public static string TryToEmptyIfNull(this string p_str) + { + if (p_str == null) + { + return string.Empty; + } + else + { + return p_str; + } + } + + public static string Left(this string str, int len) + { + string result = str.Substring(0, len); + return result; + } + + public static string Right(this string str, int len) + { + if (str.Length < len) + { + return str; + } + string result = str.Substring(str.Length - len, len); + return result; + } + + public static object IntDBNull(this object p_obj) + { + if (p_obj == null) + { + return DBNull.Value; + } + string str = p_obj?.ToString(); + int resu; + bool isSucc = int.TryParse(str, out resu); + if (isSucc) + { + return resu; + } + else + { + return DBNull.Value; + } + } + + public static object DoubleDBNull(this object p_obj) + { + if (p_obj == null) + { + return DBNull.Value; + } + string str = p_obj?.ToString(); + double resu; + bool isSucc = double.TryParse(str, out resu); + if (isSucc) + { + return resu; + } + else + { + return DBNull.Value; + } + } + + public static object DateTimeDBNull(this object p_obj) + { + if (p_obj == null) + { + return DBNull.Value; + } + string str = p_obj?.ToString(); + DateTime resu; + bool isSucc = DateTime.TryParse(str, out resu); + if (isSucc) + { + return resu; + } + else + { + return DBNull.Value; + } + } + + /// + /// 返回枚举项的描述信息。 + /// + /// 要获取描述信息的枚举项。 + /// 枚举想的描述信息。 + /// + public static string GetDescription(this Enum value, bool isTop = false) + { + Type enumType = value.GetType(); + DescriptionAttribute attr = null; + if (isTop) + { + attr = (DescriptionAttribute)Attribute.GetCustomAttribute(enumType, typeof(DescriptionAttribute)); + } + else + { + // 获取枚举常数名称。 + string name = Enum.GetName(enumType, value); + if (name != null) + { + // 获取枚举字段。 + FieldInfo fieldInfo = enumType.GetField(name); + if (fieldInfo != null) + { + // 获取描述的属性。 + attr = Attribute.GetCustomAttribute(fieldInfo, typeof(DescriptionAttribute), false) as DescriptionAttribute; + } + } + } + if (attr != null && !string.IsNullOrEmpty(attr.Description)) + { + return attr.Description; + } + else + { + return string.Empty; + } + } + + +} + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/SplitPackings/NodeTypeEnum.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/SplitPackings/NodeTypeEnum.cs new file mode 100644 index 000000000..096543b45 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/SplitPackings/NodeTypeEnum.cs @@ -0,0 +1,13 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Basedata.Domain.Shared; +public enum NodeTypeEnum +{ + ToBox = 1, + + FromBox = 2 +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/SplitPackings/OprTypeEnum.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/SplitPackings/OprTypeEnum.cs new file mode 100644 index 000000000..e87cd6f40 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/SplitPackings/OprTypeEnum.cs @@ -0,0 +1,24 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Basedata.Domain.Shared; +public enum OprTypeEnum +{ + /// + /// 其它 + /// + Other = 0, + + /// + /// 拆箱 + /// + SplitBox = 1, + + /// + /// 合箱 + /// + MergeBox = 2 +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/Win_in.Sfs.Basedata.Domain.Shared.csproj b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/Win_in.Sfs.Basedata.Domain.Shared.csproj index d91c02e6c..9d201acdf 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/Win_in.Sfs.Basedata.Domain.Shared.csproj +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain.Shared/Win_in.Sfs.Basedata.Domain.Shared.csproj @@ -1,4 +1,4 @@ - + @@ -9,6 +9,7 @@ + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Boms/BomManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Boms/BomManager.cs index 4d16dffe3..2be49a698 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Boms/BomManager.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Boms/BomManager.cs @@ -193,4 +193,24 @@ public class BomManager : DomainService, IBomManager { return await _repository.GetListAsync(p => p.Component == component).ConfigureAwait(false); } + + /// + /// 根据总成号、总成数量取所有子物料及其汇总数量 + /// + /// 总成号 + /// 总成数量 + /// + public virtual async Task> GetMaterialTotalQtyAsync(string productCode, int productNum) + { + if (productNum < 1) + { + throw new UserFriendlyException("productNum参数值必须大于等于1"); + } + var lst = await _repository.GetListAsync(p => p.Product == productCode).ConfigureAwait(false); + foreach (var item in lst) + { + item.ComponentQty = item.ComponentQty * productNum; + } + return lst; + } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Boms/IBomManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Boms/IBomManager.cs index 774719525..9687f556e 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Boms/IBomManager.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Boms/IBomManager.cs @@ -32,4 +32,13 @@ public interface IBomManager : IDomainService, IBulkImportService Task> GetListOfProductAsync(string product); Task> GetListWithPhantomItemAsync(string productItemCode, string mfgOp, DateTime validTime, bool onlyFromProductionPlan); + + /// + /// 根据总成号、总成数量取所有子物料及其汇总数量 + /// + /// 总成号 + /// 总成数量 + /// + Task> GetMaterialTotalQtyAsync(string productCode, int productNum); + } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/Equipment.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/Equipment.cs new file mode 100644 index 000000000..fbd852777 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/Equipment.cs @@ -0,0 +1,54 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.Domain.Shared.Enums.Basedata; + +namespace Win_in.Sfs.Basedata.Domain; + +/// +/// 物品基本信息 +/// +public class Equipment : SfsBaseDataAggregateRootBase, IHasCode +{ + + [IgnoreUpdate] + /// + /// 器具编号 + /// + public string Code { get; set; } + /// + /// 类型 + /// + public EnumEquipmentType Type { get; set; } + /// + /// 型号 + /// + public EnumEquipmentModel Model { get; set; } + /// + /// 库位编号 + /// + public string LocCode { get; set; } + /// + /// 状态 + /// + public int State { get; set; } + + /// + /// 创建人 + /// + public string Creator { get; set; } + + /// + /// 创建时间 + /// + public DateTime CreatTime { get; set; } + + /// + /// 标包数量 + /// + public decimal StdQty { get; set; } + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentArea.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentArea.cs new file mode 100644 index 000000000..9824ea62f --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentArea.cs @@ -0,0 +1,166 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Domain; + +/// +/// 器具基本信息 +/// +public class EquipmentArea : SfsBaseDataAggregateRootBase, IHasCode +{ + + + /// + /// 器具编号 + /// + public string Code { get; set; } + /// + /// 类型 + /// + public string Type { get; set; } + /// + /// 型号 + /// + public string Model { get; set; } + + /// + /// 库位编号 + /// + public string LocCode { get; set; } + + /// + /// 位置编号 + /// + public string AreaCode { get; set; } + + /// + /// 数量 + /// + public decimal Qty { get; set; } + /// + /// 状态 + /// + public int State { get; set; } + ///// + ///// 创建人 + ///// + //public string Creator { get; set; } + ///// + ///// 创建时间 + ///// + //public DateTime CreatTime { get; set; } + + + + + + + + + ///// + ///// 代码 + ///// + //[IgnoreUpdate] + //public string Code { get; set; } + ///// + ///// 名称 + ///// + //public string Name { get; set; } + ///// + ///// 描述 + ///// + //public string Desc1 { get; set; } + ///// + ///// 描述2 + ///// + //public string Desc2 { get; set; } + ///// + ///// 状态 + ///// + //public EnumItemStatus Status { get; set; } + ///// + ///// 制造件 + ///// + //public bool CanMake { get; set; } + ///// + ///// 采购件 + ///// + //[IgnoreUpdate] + //public bool CanBuy { get; set; } + ///// + ///// 外包件 + ///// + //public bool CanOutsourcing { get; set; } + ///// + ///// 回收件 + ///// + //public bool IsRecycled { get; set; } + + //[Display(Name = "类型")] + //public string Type { get; set; } + + //[Display(Name = "种类")] + //public string Category { get; set; } + + //[Display(Name = "分组")] + //public string Group { get; set; } + + //[Display(Name = "颜色")] + //public string Color { get; set; } + + //[Display(Name = "配置")] + //public string Configuration { get; set; } + ///// + ///// 基本计量单位 + ///// + //public string BasicUom { get; set; } + + ///// + ///// 标包数 + ///// + //public decimal StdPackQty { get; set; } + + ///// + ///// ABC类,默认为C + ///// + //public string AbcClass { get; set; } + ///// + ///// 项目 + ///// + //public string Project { get; set; } + ///// + ///// 版本 + ///// + //public string Version { get; set; } + ///// + ///// 工程变革 + ///// + //public string Eco { get; set; } + ///// + ///// 有效期 + ///// + //public int Validity { get; set; } + ///// + ///// 有效期单位 + ///// + //public EnumValidityUnit ValidityUnit { get; set; } + + ///// + ///// 管理类型 + ///// + //public EnumItemManageType ManageType { get; set; } + + ///// + ///// 打印标签用的一个等级 + ///// + //public string Elevel { get; set; } + + ///// + ///// 虚零件 + ///// + //public virtual bool IsPhantom { get; set; } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentAreaManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentAreaManager.cs new file mode 100644 index 000000000..132e7c577 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentAreaManager.cs @@ -0,0 +1,29 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; + +namespace Win_in.Sfs.Basedata.Domain; + +public class EquipmentAreaManager : DomainService, IEquipmentAreaManager +{ + private readonly IEquipmentAreaRepository _repository; + + public EquipmentAreaManager(IEquipmentAreaRepository repository) + { + _repository = repository; + } + + /// + /// 执行导入 + /// + public virtual async Task ImportDataAsync(List mergeEntities, List deleteEntities = null) + { + if (deleteEntities != null && deleteEntities.Count > 0) + { + await _repository.BulkDeleteAsync(deleteEntities).ConfigureAwait(false); + } + + await _repository.BulkMergeAsync(mergeEntities).ConfigureAwait(false); + } +} + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLoc.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLoc.cs new file mode 100644 index 000000000..17dcb0e73 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLoc.cs @@ -0,0 +1,36 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.Domain.Shared.Enums.Basedata; + +namespace Win_in.Sfs.Basedata.Domain; + +/// +/// 物品基本信息 +/// +public class EquipmentLoc : SfsBaseDataAggregateRootBase, IHasCode +{ + /// + /// 器具代码 + /// + public string Code { get; set; } + ///// + ///// 类型 + ///// + //public EquipmentType Type { get; set; } + ///// + ///// 型号 + ///// + //public EquipmentModel Model { get; set; } + /// + /// 库位代码 + /// + public string LocCode { get; set; } + /// + /// 状态 + /// + public int State { get; set; } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLocCap.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLocCap.cs new file mode 100644 index 000000000..facd32dde --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLocCap.cs @@ -0,0 +1,36 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + + +public class EquipmentLocCap:SfsAggregateRootBase, IHasCode +{ + /// + /// 器具代码 + /// + public string Code { get; set; } + /// + /// 零件号 + /// + public string PartCode { get; set; } + /// + /// 占用百分比 + /// + public decimal Percent { get; set; } + + /// + /// 录入数量 + /// + public decimal Qty { get; set; } + + /// + /// 标包数量 + /// + public decimal StdQty { get; set; } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLocCapManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLocCapManager.cs new file mode 100644 index 000000000..df81df2c1 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLocCapManager.cs @@ -0,0 +1,38 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Volo.Abp; +using Volo.Abp.Domain.Services; + +using Win_in.Sfs.Shared.Domain.Shared; + + +namespace Win_in.Sfs.Basedata.Domain; + +public class EquipmentLocCapManager : DomainService, IEquipmentLocCapManager +{ + private readonly IEquipmentLocCapRepository _repository; + + + public EquipmentLocCapManager(IEquipmentLocCapRepository repository + + ) + { + _repository = repository; + + } + + + public Task ImportDataAsync(List entities, List deleteEntities = null) + { + throw new NotImplementedException(); + } + + + + private async Task SetDetailAsync(List details) + { + + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLocManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLocManager.cs new file mode 100644 index 000000000..f6b451bab --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentLocManager.cs @@ -0,0 +1,29 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; + +namespace Win_in.Sfs.Basedata.Domain; + +public class EquipmentLocManager : DomainService, IEquipmentLocManager +{ + private readonly IEquipmentLocRepository _repository; + + public EquipmentLocManager(IEquipmentLocRepository repository) + { + _repository = repository; + } + + /// + /// 执行导入 + /// + public virtual async Task ImportDataAsync(List mergeEntities, List deleteEntities = null) + { + if (deleteEntities != null && deleteEntities.Count > 0) + { + await _repository.BulkDeleteAsync(deleteEntities).ConfigureAwait(false); + } + + await _repository.BulkMergeAsync(mergeEntities).ConfigureAwait(false); + } +} + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentManager.cs new file mode 100644 index 000000000..bc69afb6a --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentManager.cs @@ -0,0 +1,29 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; + +namespace Win_in.Sfs.Basedata.Domain; + +public class EquipmentManager : DomainService, IEquipmentManager +{ + private readonly IEquipmentRepository _repository; + + public EquipmentManager(IEquipmentRepository repository) + { + _repository = repository; + } + + /// + /// 执行导入 + /// + public virtual async Task ImportDataAsync(List mergeEntities, List deleteEntities = null) + { + if (deleteEntities != null && deleteEntities.Count > 0) + { + await _repository.BulkDeleteAsync(deleteEntities).ConfigureAwait(false); + } + + await _repository.BulkMergeAsync(mergeEntities).ConfigureAwait(false); + } +} + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentPartCode.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentPartCode.cs new file mode 100644 index 000000000..27834ba14 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentPartCode.cs @@ -0,0 +1,40 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.Domain.Shared.Enums.Basedata; + +namespace Win_in.Sfs.Basedata.Domain; + +/// +/// 器具零件关系信息 +/// +public class EquipmentPartCode : SfsBaseDataAggregateRootBase, IHasCode +{ + public string Code { get; set; } + ///// + ///// 类型 + ///// + //public EquipmentType Type { get; set; } + ///// + ///// 型号 + ///// + //public EquipmentModel Model { get; set; } + /// + /// 库位编号 + /// + public string PartCode { get; set; } + /// + /// 数量 + /// + public decimal StdQty { get; set; } + /// + /// 状态 + /// + public int State { get; set; } + /// + /// 单位 + /// + public string Unit { get; set; } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentPartCodeManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentPartCodeManager.cs new file mode 100644 index 000000000..ad208ed4a --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentPartCodeManager.cs @@ -0,0 +1,29 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; + +namespace Win_in.Sfs.Basedata.Domain; + +public class EquipmentPartCodeManager : DomainService, IEquipmentPartCodeManager +{ + private readonly IEquipmentPartCodeRepository _repository; + + public EquipmentPartCodeManager(IEquipmentPartCodeRepository repository) + { + _repository = repository; + } + + /// + /// 执行导入 + /// + public virtual async Task ImportDataAsync(List mergeEntities, List deleteEntities = null) + { + if (deleteEntities != null && deleteEntities.Count > 0) + { + await _repository.BulkDeleteAsync(deleteEntities).ConfigureAwait(false); + } + + await _repository.BulkMergeAsync(mergeEntities).ConfigureAwait(false); + } +} + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentValidator.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentValidator.cs new file mode 100644 index 000000000..6d94580b4 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/EquipmentValidator.cs @@ -0,0 +1,92 @@ +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; +using Volo.Abp.Validation; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Domain; + +//public class ItemValidator : DomainService +//{ +// private readonly IItemCategoryRepository _itemCategoryRepository; + +// public ItemValidator( +// IItemCategoryRepository itemCategoryRepository) +// { +// _itemCategoryRepository = itemCategoryRepository; +// } +// #region Check + +// public void CheckFormat(string code) +// { +// var wrongFormat = false; + +// //TODO 检查物品号的格式 + +// if (wrongFormat) +// { +// var result = new AbpValidationResult(); +// result.Errors.Add(new ValidationResult($"{code} 格式错误")); +// throw new AbpValidationException(result.Errors); +// } +// } + +// public void CheckCanMake(ItemBasic entity, bool? inputCanMake, AbpValidationResult result) +// { +// if (inputCanMake != null && inputCanMake.Value != entity.CanMake) +// { +// result.Errors.Add(new ValidationResult($"{entity.Code} {nameof(entity.CanMake)} 状态错误")); +// } +// } + +// public void CheckCanBuy(ItemBasic entity, bool? inputCanBuy, AbpValidationResult result) +// { +// if (inputCanBuy != null && inputCanBuy.Value != entity.CanBuy) +// { +// result.Errors.Add(new ValidationResult($"{entity.Code} {nameof(entity.CanBuy)} 状态错误")); +// } +// } + +// public void CheckStatus(ItemBasic entity, List validStatuses, AbpValidationResult result) +// { +// if (validStatuses.Any() && !validStatuses.Contains(entity.Status)) +// { +// result.Errors.Add(new ValidationResult($"{entity.Code} 状态错误")); +// } +// } + +// public void CheckProject(ItemBasic entity, List validProjects, AbpValidationResult result) +// { +// if (validProjects.Any() && !validProjects.Contains(entity.Project)) +// { +// result.Errors.Add(new ValidationResult($"{entity.Code} 项目错误")); +// } +// } + +// public virtual async Task CheckCategoryAsync(ItemBasic entity, Dictionary validCategories, AbpValidationResult result) +// { +// if (!validCategories.Any()) +// { +// return; +// } + +// var code = entity.Code; + +// var categories = await _itemCategoryRepository.GetListAsync(p => p.ItemCode == code).ConfigureAwait(false); + +// foreach (var category in validCategories) +// { +// var found = categories.Any(p => p.CategoryCode == category.Key +// && p.Value == category.Value); +// if (!found) +// { +// result.Errors.Add(new ValidationResult($"{code} 的 {category.Key}:{category.Value}错误")); +// } +// } + +// } + +// #endregion +//} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentAreaManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentAreaManager.cs new file mode 100644 index 000000000..f4e8156f2 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentAreaManager.cs @@ -0,0 +1,8 @@ +using Volo.Abp.Domain.Services; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IEquipmentAreaManager : IDomainService, IBulkImportService +{ +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentAreaRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentAreaRepository.cs new file mode 100644 index 000000000..2d872dcf1 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentAreaRepository.cs @@ -0,0 +1,13 @@ +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IEquipmentAreaRepository : ISfsBaseDataRepositoryBase, ISfsBulkRepositoryBase +{ + public Task UpsertAsync(EquipmentArea entity); + + public Task InsertAutoSaveAsync(EquipmentArea entity); + + public Task UpsertAsyncByInterface(EquipmentArea entity); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocCapManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocCapManager.cs new file mode 100644 index 000000000..5a62ee241 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocCapManager.cs @@ -0,0 +1,13 @@ +using System; +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain; + + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IEquipmentLocCapManager : IBulkImportService +{ + //Task OpenDetailAsync(Guid id, Guid detailId); + //Task CloseDetailAsync(Guid id, Guid detailId); + //Task CheckIsCloseAsync(string number, string supplierCode, string itemCode); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocCapRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocCapRepository.cs new file mode 100644 index 000000000..1d8089fe8 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocCapRepository.cs @@ -0,0 +1,11 @@ +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; +using Win_in.Sfs.Shared.Domain; + + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IEquipmentLocCapRepository : ISfsBaseDataRepositoryBase, ISfsBulkRepositoryBase +{ + Task UpsertAsync(EquipmentLocCap newData); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocManager.cs new file mode 100644 index 000000000..cf35e9d99 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocManager.cs @@ -0,0 +1,8 @@ +using Volo.Abp.Domain.Services; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IEquipmentLocManager : IDomainService, IBulkImportService +{ +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocRepository.cs new file mode 100644 index 000000000..a525565b7 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentLocRepository.cs @@ -0,0 +1,13 @@ +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IEquipmentLocRepository : ISfsBaseDataRepositoryBase, ISfsBulkRepositoryBase +{ + public Task UpsertAsync(EquipmentLoc entity); + + public Task InsertAutoSaveAsync(EquipmentLoc entity); + + public Task UpsertAsyncByInterface(EquipmentLoc entity); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentManager.cs new file mode 100644 index 000000000..13161ca51 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentManager.cs @@ -0,0 +1,8 @@ +using Volo.Abp.Domain.Services; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IEquipmentManager : IDomainService, IBulkImportService +{ +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentPartCodeManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentPartCodeManager.cs new file mode 100644 index 000000000..1e369d57c --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentPartCodeManager.cs @@ -0,0 +1,8 @@ +using Volo.Abp.Domain.Services; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IEquipmentPartCodeManager : IDomainService, IBulkImportService +{ +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentPartCodeRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentPartCodeRepository.cs new file mode 100644 index 000000000..2768ff9c3 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentPartCodeRepository.cs @@ -0,0 +1,13 @@ +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IEquipmentPartCodeRepository : ISfsBaseDataRepositoryBase, ISfsBulkRepositoryBase +{ + public Task UpsertAsync(EquipmentPartCode entity); + + public Task InsertAutoSaveAsync(EquipmentPartCode entity); + + public Task UpsertAsyncByInterface(EquipmentPartCode entity); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentRepository.cs new file mode 100644 index 000000000..fa12d7b40 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Equipments/IEquipmentRepository.cs @@ -0,0 +1,13 @@ +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IEquipmentRepository : ISfsBaseDataRepositoryBase, ISfsBulkRepositoryBase +{ + public Task UpsertAsync(Equipment entity); + + public Task InsertAutoSaveAsync(Equipment entity); + + public Task UpsertAsyncByInterface(Equipment entity); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/IKittingManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/IKittingManager.cs new file mode 100644 index 000000000..fa76f6b0b --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/IKittingManager.cs @@ -0,0 +1,20 @@ + +using Volo.Abp.Domain.Services; + +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IKittingManager : IDomainService, IBulkImportService +{ + //Task AddByContainerAsync(Guid traceId, string containerCode); + //// Task> AddMergeAsync(List inventories); + //Task> AddByPackingAsync(Guid traceId, List putawayInventories); + + ///// + ///// 按箱采购收货上架 根据收货时的ERP储位 物品 进行分组上架 只推荐空库位 + ///// + ///// + ///// + //Task CreateByErpCodeAndEmptyCapacityAsync(PutawayJob putawayJob); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/IKittingRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/IKittingRepository.cs new file mode 100644 index 000000000..5a5b51ebe --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/IKittingRepository.cs @@ -0,0 +1,10 @@ + +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IKittingRepository : ISfsBaseDataRepositoryBase, ISfsBulkRepositoryBase +{ + Task UpsertAsync(Kitting newData); +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/Kitting.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/Kitting.cs new file mode 100644 index 000000000..ab3e5ae38 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/Kitting.cs @@ -0,0 +1,54 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Threading.Tasks; +using NetTopologySuite.Index.HPRtree; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; + + +namespace Win_in.Sfs.Basedata.Domain; + +/// +/// Kitting箱 +/// +[Serializable] +[Display(Name = "Kitting箱")] +public class Kitting : SfsBaseDataAggregateRootBase, IHasCode +{ + public string Code { get ; set ; } + public string Name { get ; set ; } + public virtual List Details { get; set; } = new List(); + //public void SetId(Guid id) + //{ + // this.Id = id; + //} + + public void AddDetails(KittingDetail item) + { + Details.Add(item); + } + + + + + ///// + ///// 设置任务明细的实际库位和实际数量 + ///// + ///// + ///// + ///// + ///// + //public virtual async Task SetDetail(Guid id, string partCode, string desc1, string desc2, decimal qty, string conf) + //{ + // var detail = GetDetail(id); + // detail.PartCode = partCode; + // detail.Desc1 = desc1; + // detail.Desc2 = desc2; + // detail.Qty = qty; + // detail.Conf = conf; + + // await Task.CompletedTask.ConfigureAwait(false); + //} +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/KittingDetail.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/KittingDetail.cs new file mode 100644 index 000000000..37b5133a2 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/KittingDetail.cs @@ -0,0 +1,48 @@ +using System; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Volo.Abp.Domain.Entities.Auditing; +using Volo.Abp.MultiTenancy; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public class KittingDetail : AuditedEntity, IMultiTenant, IRemark + +{ + public Guid MasterId { get; set; } + /// + /// 物料编码 + /// + public string PartCode { set; get; } + /// + /// 描述1 + /// + public string Desc1 { set; get; } + /// + /// 描述2 + /// + public string Desc2 { set; get; } + /// + /// 包装数量 + /// + public decimal Qty { set; get; } + + /// + /// 配置 + /// + public string Conf { set; get; } + + public Guid? TenantId { set; get; } + + public string Remark { get; set; } + + + + public void SetId(Guid guid) + { + Id= guid; + } + + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/KittingManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/KittingManager.cs new file mode 100644 index 000000000..0be4b22b2 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/Kittings/KittingManager.cs @@ -0,0 +1,49 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.Extensions.Logging; +using Volo.Abp; +using Volo.Abp.Users; +using Volo.Abp.Validation; + +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + + +namespace Win_in.Sfs.Basedata.Domain; + +public class KittingManager : IKittingManager +{ + + + private readonly IKittingRepository _repository; + + public KittingManager(IKittingRepository repository, IWarehouseRepository warehourseRepository, ILocationRepository locationRepository) + { + _repository = repository; + } + + /// + /// 执行导入 + /// + public virtual async Task ImportDataAsync(List mergeEntities, List deleteEntities = null) + { + if (deleteEntities != null && deleteEntities.Count > 0) + { + await _repository.BulkDeleteAsync(deleteEntities).ConfigureAwait(false); + } + + await _repository.BulkMergeAsync(mergeEntities).ConfigureAwait(false); + + var insertDetails = new List(); + + foreach (var item in mergeEntities) + { + insertDetails.AddRange(item.Details); + } + + await _repository.BulkInsertAsync(insertDetails).ConfigureAwait(false); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/IPositionCodeManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/IPositionCodeManager.cs new file mode 100644 index 000000000..b8e6110ce --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/IPositionCodeManager.cs @@ -0,0 +1,9 @@ +using Volo.Abp.Domain.Services; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IPositionCodeManager : IDomainService, IBulkImportService +{ + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/IPositionCodeRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/IPositionCodeRepository.cs new file mode 100644 index 000000000..897547a28 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/IPositionCodeRepository.cs @@ -0,0 +1,8 @@ +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface IPositionCodeRepository : ISfsBaseDataRepositoryBase, ISfsBulkRepositoryBase +{ + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/PositionCode.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/PositionCode.cs new file mode 100644 index 000000000..8c5028cdb --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/PositionCode.cs @@ -0,0 +1,59 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Domain; + +/// +/// 位置码 +/// +public class PositionCode : SfsBaseDataAggregateRootBase, IHasCode +{ + /// + /// 位置代码 + /// + [Display(Name = "位置代码")] + public string Code { get; set; } + /// + /// 物料号 + /// + [Display(Name = "物料号")] + public string PartCode { get; set; } + /// + /// 物料名称 + /// + [Display(Name = "物料名称")] + public string PartName { get; set; } + /// + /// 物料描述 + /// + [Display(Name = "物料描述")] + public string PartDesc { get; set; } + /// + /// 基本计量单位 + /// + [Display(Name = "基本计量单位")] + public string BasicUom { get; set; } + /// + /// 库位 + /// + [Display(Name = "库位")] + public string LocationCode { get; set; } + /// + /// 库位名称 + /// + [Display(Name = "库位名称")] + public string LocationName { get; set; } + /// + /// 标包数量 + /// + [Display(Name = "标包数量")] + public decimal StdPackQty { get; set; } + /// + /// 类型 + /// + [Display(Name = "类型")] + public EnumRecommendType Type { get; set; } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/PositionCodeManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/PositionCodeManager.cs new file mode 100644 index 000000000..33f1dbb03 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PositionCode/PositionCodeManager.cs @@ -0,0 +1,28 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; + +namespace Win_in.Sfs.Basedata.Domain; + +public class PositionCodeManager : DomainService, IPositionCodeManager +{ + private readonly IPositionCodeRepository _repository; + + public PositionCodeManager(IPositionCodeRepository repository) + { + _repository = repository; + } + + /// + /// 执行导入 + /// + public virtual async Task ImportDataAsync(List mergeEntities, List deleteEntities = null) + { + if (deleteEntities != null && deleteEntities.Count > 0) + { + await _repository.BulkDeleteAsync(deleteEntities).ConfigureAwait(false); + } + + await _repository.BulkMergeAsync(mergeEntities).ConfigureAwait(false); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PurchasePrices/IPurchasePriceSheetRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PurchasePrices/IPurchasePriceSheetRepository.cs index 743451d79..bdb0b1a88 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PurchasePrices/IPurchasePriceSheetRepository.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PurchasePrices/IPurchasePriceSheetRepository.cs @@ -1,6 +1,8 @@ +using System.Threading.Tasks; + namespace Win_in.Sfs.Basedata.Domain; public interface IPurchasePriceSheetRepository : ISfsBaseDataRepositoryBase { - + Task UpsertAsyncByInterface(PurchasePriceSheet entity); } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PurchasePrices/PurchasePriceSheet.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PurchasePrices/PurchasePriceSheet.cs index 618868693..c0136e6fc 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PurchasePrices/PurchasePriceSheet.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/PurchasePrices/PurchasePriceSheet.cs @@ -7,32 +7,38 @@ namespace Win_in.Sfs.Basedata.Domain; /// /// 采购价格单 /// -public class PurchasePriceSheet : SfsBaseDataAggregateRootBase, IHasCode, IHasName +public class PurchasePriceSheet : SfsBaseDataAggregateRootBase { /// - /// 供应商ID + /// 物品代码 /// [IgnoreUpdate] - public Guid SupplierId { get; set; } - + public string ItemCode { get; set; } /// - /// 编码 + /// 供应商编号 /// [IgnoreUpdate] - public string Code { get; set; } - - /// - /// 价格单名称 - /// - public string Name { get; set; } + public string SupplierCode { get; set; } /// /// 价格单描述 /// public string Description { get; set; } /// - /// 货币ID + /// 采购价格 /// - public Guid CurrencyId { get; set; } + public decimal PurchasePrice { get; set; } + ///// + ///// 货币ID + ///// + //public Guid CurrencyId { get; set; } + ///// + ///// 物料价格 + ///// + //public decimal MaterialPrice { get; set; } + ///// + ///// 成品价格 + ///// + //public decimal ProductPrice { get; set; } #region details handler //public virtual void AddDetail(IGuidGenerator guidGenerator, PurchasePriceDetail detail) diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SalePrices/ISalePriceSheetRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SalePrices/ISalePriceSheetRepository.cs index 65af320fa..e7414ece9 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SalePrices/ISalePriceSheetRepository.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SalePrices/ISalePriceSheetRepository.cs @@ -1,6 +1,8 @@ +using System.Threading.Tasks; + namespace Win_in.Sfs.Basedata.Domain; public interface ISalePriceSheetRepository : ISfsBaseDataRepositoryBase { - + Task UpsertAsyncByInterface(SalePriceSheet entity); } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SalePrices/SalePriceSheet.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SalePrices/SalePriceSheet.cs index 58f356aef..785f7496e 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SalePrices/SalePriceSheet.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SalePrices/SalePriceSheet.cs @@ -7,35 +7,56 @@ namespace Win_in.Sfs.Basedata.Domain; /// /// 销售价格单 /// -public class SalePriceSheet : SfsBaseDataAggregateRootBase, IHasCode, IHasName +public class SalePriceSheet : SfsBaseDataAggregateRootBase { - - // public virtual ICollection SalePriceDetails { get; set; } - /// - /// 客户ID + /// 客户 /// [IgnoreUpdate] - public Guid CustomerId { get; set; } + public string CustomerCode { get; set; } /// - /// 编码 + /// 物料号 /// [IgnoreUpdate] - public string Code { get; set; } + public string ItemCode { get; set; } - /// - /// 价格单名称 - /// - public string Name { get; set; } /// /// 价格单描述 /// public string Description { get; set; } + /// - /// 货币ID + /// 销售价格 + /// + public decimal SalePrice { get; set; } + + // public virtual ICollection SalePriceDetails { get; set; } + + /// + /// 客户ID /// - public Guid CurrencyId { get; set; } + //[IgnoreUpdate] + //public Guid CustomerId { get; set; } + + ///// + ///// 编码 + ///// + //[IgnoreUpdate] + //public string Code { get; set; } + + ///// + ///// 价格单名称 + ///// + //public string Name { get; set; } + ///// + ///// 价格单描述 + ///// + //public string Description { get; set; } + ///// + ///// 货币ID + ///// + //public Guid CurrencyId { get; set; } #region details handler //public virtual void AddDetail(IGuidGenerator guidGenerator, SalePriceDetail detail) diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/ISplitPackingRecManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/ISplitPackingRecManager.cs new file mode 100644 index 000000000..4ce568e61 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/ISplitPackingRecManager.cs @@ -0,0 +1,27 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Volo.Abp.Domain.Services; + +namespace Win_in.Sfs.Basedata.Domain; +public interface ISplitPackingRecManager : IDomainService +{ + Task BatchInsertAsync(List input); + + /// + /// 取每个目标箱码的最后一条拆箱记录 + /// + /// 目标箱码列表 + /// + Task> GetListByToPackingCode(List toPackingCodeList); + + /// + /// 取每个源标箱码的“操作状态=其它”的拆箱记录 + /// + /// 源标箱码列表 + /// + Task> GetListByFromPackingCode(List fromPackingCodeList); + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/ISplitPackingRecRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/ISplitPackingRecRepository.cs new file mode 100644 index 000000000..9a362d808 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/ISplitPackingRecRepository.cs @@ -0,0 +1,9 @@ +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.Domain; + +public interface ISplitPackingRecRepository : ISfsBaseDataRepositoryBase +{ +} + + diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/SplitPackingRec.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/SplitPackingRec.cs new file mode 100644 index 000000000..5937bd856 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/SplitPackingRec.cs @@ -0,0 +1,186 @@ +using System; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Domain; + +/// +/// 采购标签 +/// +public class SplitPackingRec : SfsBaseDataAggregateRootBase + , IHasItem +{ + /// + /// 操作类型 + /// + public OprTypeEnum OprType { get; set; } + + /// + /// 源箱码 + /// + public string FromPackingCode { get; set; } + + /// + /// 源顶级箱码 + /// + public string FromTopPackingCode { get; set; } + + /// + /// 源标包数量 + /// + [Display(Name = "标包数量")] + [Column(TypeName = "decimal(18,6)")] + public decimal FromStdPackQty { get; set; } + + /// + /// 源计量单位 + /// + [Display(Name = "计量单位")] + [MaxLength(SfsPropertyConst.CodeLength)] + public string FromUom { get; set; } + + /// + /// 源数量 + /// + [Display(Name = "数量")] + [Column(TypeName = "decimal(18,6)")] + public decimal FromQty { get; set; } + + /// + /// 目标箱码 + /// + public string ToPackingCode { get; set; } + + /// + /// 目标顶级箱码 + /// + public string ToTopPackingCode { get; set; } + + /// + /// 目标标包数量 + /// + [Display(Name = "标包数量")] + [Column(TypeName = "decimal(18,6)")] + public decimal ToStdPackQty { get; set; } + + /// + /// 目标计量单位 + /// + [Display(Name = "计量单位")] + [MaxLength(SfsPropertyConst.CodeLength)] + public string ToUom { get; set; } + + /// + /// 目标数量 + /// + [Display(Name = "数量")] + [Column(TypeName = "decimal(18,6)")] + public decimal ToQty { get; set; } + + /// + /// 物料号 + /// + public string ItemCode { get; set; } + + /// + /// 物料名称 + /// + public string ItemName { get; set; } + + /// + /// 物料描述1 + /// + public string ItemDesc1 { get; set; } + + /// + /// 物料描述2 + /// + public string ItemDesc2 { get; set; } + + /// + /// 源批次 + /// + public string FromLot { get; set; } + + /// + /// 目标批次 + /// + public string ToLot { get; set; } + + /// + /// 采购订单 + /// + public string PurchaseInfo_PoNumber { get; set; } + + /// + /// 供应商发货单 + /// + public string PurchaseInfo_AsnNumber { get; set; } + + /// + /// 到货通知 + /// + public string ArrivalNoticNumber { get; set; } + + /// + /// 任务单【no】 + /// + public string TaskOrderNumber { get; set; } + + /// + /// 收货记录单【no】 + /// + public string ReceiptRecNumber { get; set; } + + /// + /// 上架单【no】 + /// + public string PutOnShelfNumber { get; set; } + + public EnumLabelType LabelType { get; set; } +} + +/// +/// 标签类别 +/// +public enum EnumLabelType +{ + /// + /// 空枚举 + /// + [Display(Name = "未定义")] + None = 0, + + /// + /// 采购标签 + /// + [Display(Name = "采购标签")] + PurchaseLabel = 1, + + /// + /// 生产标签 + /// + [Display(Name = "生产标签")] + ProductionLabel = 2, + + /// + /// 销售标签 + /// + [Display(Name = "销售标签")] + SaleLabel = 3, + + /// + /// 托盘标签 + /// + [Display(Name = "托盘标签")] + PalletLabel = 4, + + /// + /// 盘点标签 + /// + [Display(Name = "盘点标签")] + CountLabel = 5, +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/SplitPackingRecManager.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/SplitPackingRecManager.cs new file mode 100644 index 000000000..fec61d5b1 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/SplitPackings/SplitPackingRecManager.cs @@ -0,0 +1,200 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.EntityFrameworkCore; +using Volo.Abp; +using Volo.Abp.Domain.Services; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Domain.Shared; + +namespace Win_in.Sfs.Basedata.Domain; +public class SplitPackingRecManager : DomainService, ISplitPackingRecManager +{ + private readonly ISplitPackingRecRepository _repository; + private readonly IObjectMapper _autoMapper; + //private readonly ILabelDefinitionManager _labelDefinitionManager; + + public SplitPackingRecManager(ISplitPackingRecRepository repository, IObjectMapper autoMapper) //, ILabelDefinitionManager labelDefinitionManager + { + _repository = repository; + _autoMapper = autoMapper; + //_labelDefinitionManager = labelDefinitionManager; + } + + public async Task BatchInsertAsync(List input) + { + var query = await _repository.GetQueryableAsync().ConfigureAwait(false); + foreach (SplitPackingRec item in input) + { + #region 校验 + if (item.OprType == OprTypeEnum.SplitBox || item.OprType == OprTypeEnum.MergeBox) //拆箱或合箱 + { + if (item.FromPackingCode == item.ToPackingCode) + { + throw new UserFriendlyException("操作类型是拆箱或合箱状态,源箱码和目标箱码不能相同!"); + } + } + else //入库 + { + if (item.FromPackingCode != item.ToPackingCode) + { + throw new UserFriendlyException("操作类型不是拆箱或合箱状态,源箱码和目标箱码必须相同!"); + } + if (item.FromTopPackingCode.IsNullOrEmpty()) + { + item.FromTopPackingCode = item.FromPackingCode; + } + if (item.ToTopPackingCode.IsNullOrEmpty()) + { + item.ToTopPackingCode = item.ToPackingCode; + } + } + #endregion + + if (item.OprType == OprTypeEnum.SplitBox || item.OprType == OprTypeEnum.MergeBox) + { + //设置顶级箱码 + item.FromTopPackingCode = GetTopPackingCode(query, item.FromPackingCode); + item.ToTopPackingCode = GetTopPackingCode(query, item.ToPackingCode); + if (item.FromTopPackingCode.IsNullOrEmpty()) + { + item.FromTopPackingCode = item.FromPackingCode; + } + if (item.ToTopPackingCode.IsNullOrEmpty()) + { + item.ToTopPackingCode = item.FromTopPackingCode; + } + //设置六个单据号 + SetBillNumber(query, item); + //拆箱时,如果目标箱不存在,插入目标箱(两个箱码相同) + string toPackCode = item.ToPackingCode; + var toHis = await query.Where(itm => itm.FromPackingCode == toPackCode && itm.ToPackingCode == toPackCode).OrderBy(itm => itm.CreationTime).FirstOrDefaultAsync().ConfigureAwait(false); + if (toHis == null) + { + + SplitPackingRec newObj = CommonHelper.CloneObj(item); + newObj.SetId(GuidGenerator.Create()); + newObj.OprType = OprTypeEnum.Other; + newObj.FromPackingCode = newObj.ToPackingCode; + newObj.FromTopPackingCode = newObj.ToTopPackingCode; + newObj.FromStdPackQty = newObj.ToStdPackQty; + newObj.FromUom = newObj.ToUom; + newObj.FromQty = newObj.ToQty; + newObj.FromLot = newObj.ToLot; + var res = await _repository.InsertAsync(newObj, true).ConfigureAwait(false); + } + SplitPackingRec newEntity = CommonHelper.CloneObj(item); + newEntity.SetId(GuidGenerator.Create()); + var ret = await _repository.InsertAsync(newEntity, true).ConfigureAwait(false); + } + else + { + SplitPackingRec newEntity = CommonHelper.CloneObj(item); + newEntity.SetId(GuidGenerator.Create()); + var ret = await _repository.InsertAsync(newEntity, true).ConfigureAwait(false); + } + } //foreach + return true; + } + + /// + /// 取每个目标箱码的最后一条拆箱记录 + /// + /// 目标箱码列表 + /// + public async Task> GetListByToPackingCode(List toPackingCodeList) + { + List ret = new List(); + List lst = await _repository.GetListAsync( + itm => toPackingCodeList.Contains(itm.ToPackingCode) + && itm.OprType == OprTypeEnum.SplitBox).ConfigureAwait(false); + + foreach (string toCode in toPackingCodeList) + { + var obj = lst.Where(itm => itm.ToPackingCode == toCode) + .OrderByDescending(itm => itm.CreationTime).FirstOrDefault(); + if (obj != null) + { + ret.Add(obj); + } + } + return ret; + } + + /// + /// 取每个源标箱码的“操作状态=其它”的拆箱记录 + /// + /// 源标箱码列表 + /// + public async Task> GetListByFromPackingCode(List fromPackingCodeList) + { + List ret = new List(); + List lst = await _repository.GetListAsync( + itm => fromPackingCodeList.Contains(itm.FromPackingCode) + && itm.OprType == OprTypeEnum.SplitBox).ConfigureAwait(false); + + foreach (string fromCode in fromPackingCodeList) + { + var obj = lst.Where(itm => itm.FromPackingCode == fromCode && itm.OprType == OprTypeEnum.Other) + .OrderByDescending(itm => itm.CreationTime).FirstOrDefault(); + if (obj != null) + { + ret.Add(obj); + } + } + return ret; + } + + /// + /// 取顶级箱码 + /// + /// 箱码历史 + /// 当前箱码 + /// + private static string GetTopPackingCode(IQueryable historyQuery, string packingCode) + { + var historyRec = historyQuery.Where(itm => itm.FromPackingCode == packingCode).OrderBy(itm => itm.CreationTime).FirstOrDefault(); + if (historyRec != null) + { + return historyRec.FromTopPackingCode; + } + else + { + historyRec = historyQuery.Where(itm => itm.ToPackingCode == packingCode).OrderBy(itm => itm.CreationTime).FirstOrDefault(); + if (historyRec != null) + { + return historyRec.ToTopPackingCode; + } + } + return null; + } + + private static void SetBillNumber(IQueryable historyQuery, SplitPackingRec obj) + { + var historyRec = historyQuery.Where(itm => itm.FromPackingCode == obj.FromPackingCode).OrderBy(itm => itm.CreationTime).FirstOrDefault(); + if (historyRec != null) + { + obj.PurchaseInfo_PoNumber = historyRec.PurchaseInfo_PoNumber; //采购订单 + obj.PurchaseInfo_AsnNumber = historyRec.PurchaseInfo_AsnNumber; //供应商发货单 + obj.ArrivalNoticNumber = historyRec.ArrivalNoticNumber; //到货通知 + obj.TaskOrderNumber = historyRec.TaskOrderNumber; //任务单 + obj.ReceiptRecNumber = historyRec.ReceiptRecNumber; //收货记录单 + obj.PutOnShelfNumber = historyRec.PutOnShelfNumber; //上架单 + } + //else + //{ + // historyRec = historyQuery.Where(itm => itm.ToPackingCode == obj.ToPackingCode).OrderBy(itm => itm.CreationTime).FirstOrDefault(); + // if (historyRec != null) + // { + // obj.PurchaseInfo_PoNumber = historyRec.PurchaseInfo_PoNumber; //采购订单 + // obj.PurchaseInfo_AsnNumber = historyRec.PurchaseInfo_AsnNumber; //供应商发货单 + // obj.ArrivalNoticNumber = historyRec.ArrivalNoticNumber; //到货通知 + // obj.TaskOrderNumber = historyRec.TaskOrderNumber; //任务单 + // obj.ReceiptRecNumber = historyRec.ReceiptRecNumber; //收货记录单 + // obj.PutOnShelfNumber = historyRec.PutOnShelfNumber; //上架单 + // } + //} + } + +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/StdCostPrices/IStdCostPriceSheetRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/StdCostPrices/IStdCostPriceSheetRepository.cs index 00dbb4898..c03d20090 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/StdCostPrices/IStdCostPriceSheetRepository.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/StdCostPrices/IStdCostPriceSheetRepository.cs @@ -1,5 +1,8 @@ +using System.Threading.Tasks; + namespace Win_in.Sfs.Basedata.Domain; public interface IStdCostPriceSheetRepository : ISfsBaseDataRepositoryBase { + Task UpsertAsyncByInterface(StdCostPriceSheet entity); } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/StdCostPrices/StdCostPriceSheet.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/StdCostPrices/StdCostPriceSheet.cs index 6100cabd5..c3306bbd5 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/StdCostPrices/StdCostPriceSheet.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.Domain/StdCostPrices/StdCostPriceSheet.cs @@ -8,33 +8,46 @@ namespace Win_in.Sfs.Basedata.Domain; /// /// 标准成本价格单-主表 /// -public class StdCostPriceSheet : SfsBaseDataAggregateRootBase, IHasCode, IHasName +public class StdCostPriceSheet : SfsBaseDataAggregateRootBase { - [Display(Name = "编码")] - [Required(ErrorMessage = "{0}是必填项")] - [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + /// + /// 物品代码 + /// [IgnoreUpdate] - public string Code { get; set; } + public string ItemCode { get; set; } + /// + /// 价格单描述 + /// + public string Description { get; set; } + /// + /// 标准成本价格 + /// + public decimal StdCostPrice { get; set; } + //[Display(Name = "编码")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + //[IgnoreUpdate] + //public string Code { get; set; } - [Display(Name = "价格单名称")] - [Required(ErrorMessage = "{0}是必填项")] - [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] - [IgnoreUpdate] - public string Name { get; set; } + //[Display(Name = "价格单名称")] + //[Required(ErrorMessage = "{0}是必填项")] + //[StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + //[IgnoreUpdate] + //public string Name { get; set; } - [Display(Name = "供应商Id")] - [Required(ErrorMessage = "{0}是必填项")] - [IgnoreUpdate] - public Guid SupplierId { get; set; } + //[Display(Name = "供应商Id")] + //[Required(ErrorMessage = "{0}是必填项")] + //[IgnoreUpdate] + //public Guid SupplierId { get; set; } - [Display(Name = "价格单描述")] - [StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] - [IgnoreUpdate] - public string Description { get; set; } + //[Display(Name = "价格单描述")] + //[StringLength(SfsEfCorePropertyConst.DescLength, ErrorMessage = "{0}最多输入{1}个字符")] + //[IgnoreUpdate] + //public string Description { get; set; } - [Display(Name = "货币Id")] - [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] - [IgnoreUpdate] - public Guid CurrencyId { get; set; } + //[Display(Name = "货币Id")] + //[StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + //[IgnoreUpdate] + //public Guid CurrencyId { get; set; } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataDbContext.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataDbContext.cs index 1dbbf4cb5..239048798 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataDbContext.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataDbContext.cs @@ -42,7 +42,6 @@ public class BasedataDbContext : AbpDbContext, IBasedataDbCon public DbSet WorkShops { get; set; } public DbSet Docks { get; set; } public DbSet LocationGroups { get; set; } - public DbSet Locations { get; set; } public DbSet ProductionLines { get; set; } public DbSet WorkGroups { get; set; } @@ -51,9 +50,13 @@ public class BasedataDbContext : AbpDbContext, IBasedataDbCon public DbSet SupplierTimeWindows { get; set; } public DbSet ErpLocation { get; set; } public DbSet CustomerAddresses { get; set; } - public DbSet ItemGuideBooks { get; set; } public DbSet Dicts { get; set; } + public DbSet PositionCodes { get; set; } + + public DbSet Equipments { get; set; } + + public DbSet SplitPackingRecs { get; set; } public BasedataDbContext(DbContextOptions options) : base(options) diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataDbContextModelCreatingExtensions.cs index ad0cabba6..cb9249054 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataDbContextModelCreatingExtensions.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataDbContextModelCreatingExtensions.cs @@ -63,8 +63,14 @@ public static class BasedataDbContextModelCreatingExtensions builder.ConfigureCustomerAddress(options); builder.ConfigureItemGuideBook(options); builder.ConfigureDocumentSetting(options); + builder.ConfigureEquipment(options); //设置decimal的默认小数位数 builder.ConfigurePrecisionOfDecimal(); + builder.ConfigurePositionCode(options); + builder.ConfigureSplitPackingRec(options); + builder.ConfigureKitting(options); + builder.ConfigureEquipmentLoc(options); + builder.ConfigureEquipmentPartCode(options); } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataEntityFrameworkCoreModule.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataEntityFrameworkCoreModule.cs index 3193de4a3..c2fa0071a 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataEntityFrameworkCoreModule.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/BasedataEntityFrameworkCoreModule.cs @@ -54,6 +54,7 @@ public class BasedataEntityFrameworkCoreModule : AbpModule context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); + context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); @@ -67,6 +68,13 @@ public class BasedataEntityFrameworkCoreModule : AbpModule context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); + context.Services.AddTransient(); + context.Services.AddTransient(); + context.Services.AddTransient(); + context.Services.AddTransient(); + context.Services.AddTransient(); + context.Services.AddTransient(); + context.Services.AddTransient(); ConfigureEntity(); } @@ -78,6 +86,11 @@ public class BasedataEntityFrameworkCoreModule : AbpModule { orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Items); }); + options.Entity(orderOptions => + { + orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details); + }); + }); diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentAreaDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentAreaDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..cda151bd4 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentAreaDbContextModelCreatingExtensions.cs @@ -0,0 +1,39 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.EntityFrameworkCore; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public static class EquipmentAreaDbContextModelCreatingExtensions +{ + public static void ConfigureEquipmentArea(this ModelBuilder builder, BasedataModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(EquipmentArea), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + + //Properties + b.Property(q => q.Code).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength).IsRequired(true); + b.Property(q => q.Model).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.LocCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.Type).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.AreaCode).HasMaxLength(SfsPropertyConst.CodeLength); + + + b.HasIndex(q => new { q.Code }); + b.HasIndex(q => new { q.AreaCode }); + }); + } +} + + +/// +/// 器具编号 +/// diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentAreaEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentAreaEfCoreRepository.cs new file mode 100644 index 000000000..99b6cbd46 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentAreaEfCoreRepository.cs @@ -0,0 +1,56 @@ +using System; +using System.Threading.Tasks; +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public class EquipmentAreaEfCoreRepository : SfsBaseDataEfCoreRepositoryBase, IEquipmentAreaRepository, ISfsBulkRepositoryBase +{ + public EquipmentAreaEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } + public virtual async Task UpsertAsyncByInterface(EquipmentArea entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code && p.AreaCode==entity.AreaCode).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + } + else + { + exist.State = entity.State; + exist.Model = entity.Model; + exist.Type = entity.Type; + exist.LastModificationTime = DateTimeOffset.Now.DateTime; + + } + } + public virtual async Task UpsertAsync(EquipmentArea entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code && p.AreaCode==entity.AreaCode).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + } + else + { + exist.State = entity.State; + exist.Model = entity.Model; + exist.Type = entity.Type; + exist.LastModificationTime = DateTimeOffset.Now.DateTime; + + } + + + } + + public virtual async Task InsertAutoSaveAsync(EquipmentArea entity) + { + _ = await InsertAsync(entity, true, GetCancellationToken()).ConfigureAwait(false); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..37b9c9852 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentDbContextModelCreatingExtensions.cs @@ -0,0 +1,65 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.EntityFrameworkCore; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public static class EquipmentDbContextModelCreatingExtensions +{ + public static void ConfigureEquipment(this ModelBuilder builder, BasedataModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(Equipment), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + + //Properties + b.Property(q => q.Code).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength).IsRequired(true); + b.Property(q => q.Model).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.LocCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.Type).HasMaxLength(SfsPropertyConst.CodeLength); + + + //Relations + //None + + //Indexes + b.HasIndex(q => new { q.Code }).IsUnique(); + }); + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(EquipmentLocCap), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + + //Properties + b.Property(q => q.Code).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength).IsRequired(true); + b.Property(q => q.PartCode).HasMaxLength(SfsPropertyConst.CodeLength); + + + //Relations + //None + + //Indexes + b.HasIndex(q => new { q.Code }).IsUnique(); + }); + + + + + } +} + + +/// +/// 器具编号 +/// diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentEfCoreRepository.cs new file mode 100644 index 000000000..1d52ed2b1 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentEfCoreRepository.cs @@ -0,0 +1,72 @@ +using System; +using System.Threading.Tasks; +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public class EquipmentEfCoreRepository : SfsBaseDataEfCoreRepositoryBase, IEquipmentRepository, ISfsBulkRepositoryBase +{ + public EquipmentEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } + public virtual async Task UpsertAsyncByInterface(Equipment entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + + + + var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + + + var cap = new EquipmentLocCap() { Code = entity.Code,PartCode=string.Empty,Percent=0, Qty=0 , StdQty=0 }; + + await DbContext.Set().AddAsync(cap).ConfigureAwait(false); + + + } + else + { + exist.State = entity.State; + exist.Model = entity.Model; + exist.Type = entity.Type; + exist.LastModificationTime = DateTimeOffset.Now.DateTime; + + } + } + public virtual async Task UpsertAsync(Equipment entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + + + + var cap = new EquipmentLocCap() { Code = entity.Code, PartCode = string.Empty, Percent = 0, Qty = 0, StdQty = 0 }; + + await DbContext.Set().AddAsync(cap).ConfigureAwait(false); + + + + } + else + { + exist.State = entity.State; + exist.Model = entity.Model; + exist.Type = entity.Type; + exist.LastModificationTime = DateTimeOffset.Now.DateTime; + } + } + + public virtual async Task InsertAutoSaveAsync(Equipment entity) + { + _ = await InsertAsync(entity, true, GetCancellationToken()).ConfigureAwait(false); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentLocCapEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentLocCapEfCoreRepository.cs new file mode 100644 index 000000000..6315ea9e0 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentLocCapEfCoreRepository.cs @@ -0,0 +1,66 @@ +using System; +using System.Threading.Tasks; +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public class EquipmentLocCapEfCoreRepository : SfsBaseDataEfCoreRepositoryBase, IEquipmentLocCapRepository, ISfsBulkRepositoryBase +{ + public EquipmentLocCapEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } + public virtual async Task UpsertAsyncByInterface(EquipmentLocCap entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + + + + var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + + + + + } + else + { + exist.Qty = entity.Qty; + exist.StdQty = entity.StdQty; + exist.Percent = entity.Percent; + exist.LastModificationTime = DateTimeOffset.Now.DateTime; + + } + } + public virtual async Task UpsertAsync(EquipmentLocCap entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + + var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + + + + + } + else + { + exist.Qty = entity.Qty; + exist.StdQty = entity.StdQty; + exist.Percent = entity.Percent; + exist.LastModificationTime = DateTimeOffset.Now.DateTime; + + } + } + + public virtual async Task InsertAutoSaveAsync(EquipmentLocCap entity) + { + _ = await InsertAsync(entity, true, GetCancellationToken()).ConfigureAwait(false); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentLocDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentLocDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..442d052a8 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentLocDbContextModelCreatingExtensions.cs @@ -0,0 +1,40 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.EntityFrameworkCore; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public static class EquipmentLocDbContextModelCreatingExtensions +{ + public static void ConfigureEquipmentLoc(this ModelBuilder builder, BasedataModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(EquipmentLoc), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + + //Properties + b.Property(q => q.Code).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength).IsRequired(true); + b.Property(q => q.LocCode).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength).IsRequired(true); + + + + //Relations + //None + + //Indexes + b.HasIndex(q => new { q.Code ,q.LocCode}).IsUnique(); + }); + } +} + + +/// +/// 器具编号 +/// diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentLocEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentLocEfCoreRepository.cs new file mode 100644 index 000000000..8d3734d85 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentLocEfCoreRepository.cs @@ -0,0 +1,54 @@ +using System; +using System.Threading.Tasks; +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public class EquipmentLocEfCoreRepository : SfsBaseDataEfCoreRepositoryBase, IEquipmentLocRepository, ISfsBulkRepositoryBase +{ + public EquipmentLocEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } + public virtual async Task UpsertAsyncByInterface(EquipmentLoc entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + } + else + { + exist.State = entity.State; + + exist.LastModificationTime = DateTimeOffset.Now.DateTime; + + } + } + public virtual async Task UpsertAsync(EquipmentLoc entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + } + else + { + exist.State = entity.State; + + exist.LastModificationTime = DateTimeOffset.Now.DateTime; + + } + + + } + + public virtual async Task InsertAutoSaveAsync(EquipmentLoc entity) + { + _ = await InsertAsync(entity, true, GetCancellationToken()).ConfigureAwait(false); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentPartCodeDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentPartCodeDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..055fe60a9 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentPartCodeDbContextModelCreatingExtensions.cs @@ -0,0 +1,40 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.EntityFrameworkCore; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public static class EquipmentPartCodeDbContextModelCreatingExtensions +{ + public static void ConfigureEquipmentPartCode(this ModelBuilder builder, BasedataModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(EquipmentPartCode), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + + //Properties + b.Property(q => q.Code).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength).IsRequired(true); + b.Property(q => q.PartCode).HasMaxLength(SfsPropertyConst.CodeLength).IsRequired(true); + + + + //Relations + //None + + //Indexes + b.HasIndex(q => new { q.Code,q.PartCode }).IsUnique(); + }); + } +} + + +/// +/// 器具编号 +/// diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentPartCodeEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentPartCodeEfCoreRepository.cs new file mode 100644 index 000000000..a9b50c45d --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Equipments/EquipmentPartCodeEfCoreRepository.cs @@ -0,0 +1,68 @@ +using System; +using System.Threading.Tasks; +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public class EquipmentPartCodeEfCoreRepository : SfsBaseDataEfCoreRepositoryBase, IEquipmentPartCodeRepository, ISfsBulkRepositoryBase +{ + public EquipmentPartCodeEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } + public virtual async Task UpsertAsyncByInterface(EquipmentPartCode entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + var exist = await dbSet.FirstOrDefaultAsync(p => p.Code== entity.Code).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + } + else + { + exist.State = entity.State; + + exist.LastModificationTime = DateTimeOffset.Now.DateTime; + + } + } + public virtual async Task UpsertAsync(EquipmentPartCode entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + } + else + { + exist.State = entity.State; + + exist.LastModificationTime = DateTimeOffset.Now.DateTime; + + } + + // var context = await GetDbContextAsync(); + // await context.SingleMergeAsync(entity, options => + // { + // //业务主键,可以是联合主键 + // options.ColumnPrimaryKeyExpression = c => new + // { + // c.Code + // }; + // //需要在更新时忽略的属性 + // options.IgnoreOnMergeUpdateExpression = c => new + // { + // c.Id, + // c.ManageType, + // }; + // }); + } + + public virtual async Task InsertAutoSaveAsync(EquipmentPartCode entity) + { + _ = await InsertAsync(entity, true, GetCancellationToken()).ConfigureAwait(false); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/IBasedataDbContext.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/IBasedataDbContext.cs index f68df94f9..c259efd44 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/IBasedataDbContext.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/IBasedataDbContext.cs @@ -50,4 +50,8 @@ public interface IBasedataDbContext : IEfCoreDbContext public DbSet SupplierTimeWindows { get; } public DbSet ErpLocation { get; } public DbSet CustomerAddresses { get; } + + public DbSet SplitPackingRecs { get; set; } + + } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Kittings/KittingDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Kittings/KittingDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..8c4d1a813 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Kittings/KittingDbContextModelCreatingExtensions.cs @@ -0,0 +1,81 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.EntityFrameworkCore; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public static class KittingDbContextModelCreatingExtensions +{ + public static void ConfigureKitting(this ModelBuilder builder, BasedataModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(Kitting), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + b.Property(p => p.Name).HasMaxLength(SfsPropertyConst.DescLength); + //Properties + b.Property(q => q.Code).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + //Relations + b.HasMany(q => q.Details).WithOne().HasForeignKey(d => d.MasterId).IsRequired(); + + + + + + //Indexes + b.HasIndex(q => new { q.Code }).IsUnique(); + }); + builder.Entity(b => + { + + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(KittingDetail), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + + b.Property(p => p.Desc1).HasMaxLength(SfsPropertyConst.DescLength); + //Properties + b.Property(q => q.Desc2).HasMaxLength(SfsPropertyConst.CodeLength); + //Relations + b.Property(q => q.MasterId).IsRequired(); + //Indexes + + + //b.HasMany(q => q.Details).WithOne().HasForeignKey(d => d.MasterID).IsRequired(); + + + + }); + } + //public static void ConfigureCustomer(this ModelBuilder builder, BasedataModelBuilderConfigurationOptions options) + //{ + // builder.Entity(b => + // { + // //Configure table & schema name + // b.ToTable(options.TablePrefix + nameof(Customer), options.Schema); + // //Configure ABP properties + // b.ConfigureByConvention(); + // //Configure Sfs base properties + // b.ConfigureSfsBase(); + + // //Properties + // b.Property(q => q.Code).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + // b.Property(q => q.Name).HasMaxLength(SfsPropertyConst.NameLength); + // b.Property(q => q.Description).HasMaxLength(SfsPropertyConst.DescLength); + + // //Relations + // //None + + // //Indexes + // b.HasIndex(q => new { q.Code }).IsUnique(); + // }); + //} +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Kittings/KittingEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Kittings/KittingEfCoreRepository.cs new file mode 100644 index 000000000..24cccf4b8 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Kittings/KittingEfCoreRepository.cs @@ -0,0 +1,212 @@ + +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public class KittingEfCoreRepository : SfsBaseDataEfCoreRepositoryBase, IKittingRepository, ISfsBulkRepositoryBase +{ + public KittingEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } + + public virtual async Task UpsertAsync(Kitting newData) + { + var main=DbContext.Set(); + var detail=DbContext.Set(); + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + var exist = await main.FirstOrDefaultAsync(p => p.Code == newData.Code).ConfigureAwait(false); + if (exist == null) + { + newData.SetId(GuidGenerator.Create()); + await InsertAsync(newData).ConfigureAwait(false); + } + else + { + var detailList= detail.Where(p => p.MasterId == exist.Id).ToList(); + + var left=from itm in newData.Details join itm1 in detailList on + itm.PartCode equals itm1.PartCode + into temp + from tm in temp.DefaultIfEmpty() + where tm == null + select itm; + var inner = from itm in detailList + join itm1 in newData.Details on + itm.PartCode equals itm1.PartCode + select itm1; + //await detail.AddRangeAsync(left.ToList()).ConfigureAwait(false); + + List insert = new List(); + List update = new List(); + foreach (var itm in inner.ToList()) + { + var first=newData.Details.FirstOrDefault(p=>p.PartCode==itm.PartCode); + itm.Qty = first.Qty; + itm.Desc1= first.Desc1; + itm.Desc2=first.Desc2; + update.Add(itm); + + } + + foreach (var itm in left.ToList()) + { + itm.SetId(GuidGenerator.Create()); + itm.MasterId = exist.Id; + insert.Add(itm); + } + + detail.AddRange(insert.ToArray()); + + detail.UpdateRange(update.ToArray()); + + + + DbContext.SaveChanges(); + + + + + + //foreach (var itm in detail) + //{ + // var existDetail = + // detailList.FirstOrDefault(p => p.PartCode == newDetail.PartCode); + + //} + + + //detailRep.Where(p=>p.PartCode==); + + + //exist.Name = newData.Name; + + //UpsertDetail(newData, exist); + + //await UpdateAsync(exist).ConfigureAwait(false); + } + } + + //private void UpsertDetail(List newData, List exist) + //{ + // foreach (var newDetail in newData) + // { + // var existDetail = + // exist.FirstOrDefault(p =>p.PartCode==newDetail.PartCode); + // if (existDetail == null) + // { + // newDetail.SetId(GuidGenerator.Create()); + // newDetail.MasterId = exist.Id; + // exist.Details.Add(newDetail); + // } + // else + // { + // existDetail.Desc1= newDetail.Desc1; + // existDetail.Desc2= newDetail.Desc2; + // existDetail.Qty= newDetail.Qty; + // existDetail.Remark= newDetail.Remark; + + // //existDetail.SupplierPackUom = newDetail.SupplierPackUom; + // //existDetail.SupplierPackQty = newDetail.SupplierPackQty; + // //existDetail.ConvertRate = newDetail.ConvertRate; + // //existDetail.IsConsignment = newDetail.IsConsignment; + // //existDetail.LineStatus = newDetail.LineStatus; + // //existDetail.Uom = newDetail.Uom; + // //existDetail.Qty = newDetail.Qty; + // //existDetail.StdPackQty = newDetail.StdPackQty; + // //existDetail.ItemName = newDetail.ItemName; + // //existDetail.ItemDesc1 = newDetail.ItemDesc1; + // //existDetail.ItemDesc2 = newDetail.ItemDesc2; + // //existDetail.ItemCode = newDetail.ItemCode; + // //existDetail.Remark = newDetail.Remark; + // } + // } + //} + + + + + + + + + + + + + + + + + + + + + //public virtual async Task UpsertAsync(Kitting entity) + //{ + // var dbSet = await GetDbSetAsync().ConfigureAwait(false); + // var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code).ConfigureAwait(false); + // if (exist == null) + // { + // var insRet = await InsertAsync(entity).ConfigureAwait(false); + // } + // else + // { + + + + // //exist.Code = entity.Code; + // exist.Name = entity.Name; + // //exist.Address = entity.Address; + // //exist.Country = entity.Country; + // //exist.City = entity.City; + // //exist.Phone = entity.Phone; + // //exist.Fax = entity.Fax; + // //exist.PostID = entity.PostID; + // //exist.Contacts = entity.Contacts; + // //exist.Currency = entity.Currency; + // //exist.IsActive = entity.IsActive; + // //exist.Type = entity.Type; + // exist.TenantId = entity.TenantId; + // exist.Remark = entity.Remark; + + // } + // // var context = await GetDbContextAsync(); + // // await context.SingleMergeAsync(entity, options => + // // { + // // //业务主键,可以是联合主键 + // // options.ColumnPrimaryKeyExpression = c => new + // // { + // // c.Company, + // // c.Code + // // }; + // // //需要在更新时忽略的属性 + // // options.IgnoreOnMergeUpdateExpression = c => new + // // { + // // c.Id, + // // }; + // // }); + //} + + + //public virtual async Task UpsertAsyncByInterface(Kitting entity) + //{ + // //var dbSet = await GetDbSetAsync().ConfigureAwait(false); + // //var exist = await dbSet.FirstOrDefaultAsync(p => p.Code == entity.Code).ConfigureAwait(false); + // //if (exist == null) + // //{ + // // var insRet = await InsertAsync(entity).ConfigureAwait(false); + // //} + // //else + // //{ + // // exist.Name = entity.Name; + // // exist.ShortName = entity.ShortName; + // // exist.LastModificationTime = DateTime.Now; + // //} + //} +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103025940_Init20230103.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103025940_Init20230103.Designer.cs deleted file mode 100644 index c3a1fecd5..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103025940_Init20230103.Designer.cs +++ /dev/null @@ -1,4648 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - [Migration("20230103025940_Init20230103")] - partial class Init20230103 - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("Relational:MaxIdentifierLength", 128) - .HasAnnotation("ProductVersion", "5.0.17") - .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty", "Company") - .IsUnique(); - - b.ToTable("Basedata_AQL"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .HasColumnType("int"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Area"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AreaItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Allowed") - .HasColumnType("bit"); - - b.Property("AreaId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UomId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Company", "AreaId", "ItemId") - .IsUnique(); - - b.ToTable("Basedata_AreaItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .HasColumnType("int"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .HasColumnType("int"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Company", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company") - .IsUnique(); - - b.ToTable("Basedata_Calendar"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Category"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Company", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FullName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Logo") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PrimaryProduct") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Company"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Configuration", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Key") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Company") - .IsUnique(); - - b.ToTable("Basedata_Configuration"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Currency"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Customer"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerBom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ChildItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FailureTime") - .HasColumnType("datetime2"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ParentItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CustomerId", "ParentItemId", "ChildItemId") - .IsUnique(); - - b.ToTable("Basedata_CustomerBom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Dict"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Dock"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .HasColumnType("nvarchar(450)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique() - .HasFilter("[Company] IS NOT NULL"); - - b.ToTable("Basedata_InterfaceCalendar"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InventoryRoute", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_InventoryRoute"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .HasColumnType("int"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLine") - .HasColumnType("nvarchar(max)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .HasColumnType("int"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CategoryCode", "ItemCode", "Value") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "Company") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConversionRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsStdPack") - .HasMaxLength(64) - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company", "ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "Company", "StoreRelationType", "StoreValue"); - - b.ToTable("Basedata_ItemSafetyStock"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "Company", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineAggregateRootId") - .HasColumnType("uniqueidentifier"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineAggregateRootId"); - - b.HasIndex("WorkStationId"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Machine"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Param", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Param"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProdLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode", "Company") - .IsUnique(); - - b.ToTable("Basedata_ProdLineItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Project"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Route", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Route"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Rule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Rule"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Shift"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Strategy", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Strategy"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StrategyRule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RuleId") - .HasColumnType("uniqueidentifier"); - - b.Property("Seq") - .HasColumnType("int"); - - b.Property("StrategyId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("StrategyId", "RuleId", "Company") - .IsUnique(); - - b.ToTable("Basedata_StrategyRule"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Supplier"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "Company") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTime", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "Company", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTime"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Team"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .HasColumnType("int"); - - b.Property("TransType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType", "Company") - .IsUnique(); - - b.ToTable("Basedata_TransactionType"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Uom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Warehouse"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_WorkShop"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_WorkStation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("BomId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("BomId"); - - b1.ToTable("Basedata_Bom"); - - b1.WithOwner() - .HasForeignKey("BomId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PerQty", b1 => - { - b1.Property("BomId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BomId"); - - b1.ToTable("Basedata_Bom"); - - b1.WithOwner() - .HasForeignKey("BomId"); - }); - - b.Navigation("PerQty"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CalendarId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CalendarId"); - - b1.ToTable("Basedata_Calendar"); - - b1.WithOwner() - .HasForeignKey("CalendarId"); - }); - - b.Navigation("TimeRange") - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CustomerItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CustomerItemId"); - - b1.ToTable("Basedata_CustomerItem"); - - b1.WithOwner() - .HasForeignKey("CustomerItemId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "CustomerPackQty", b1 => - { - b1.Property("CustomerItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerItemId"); - - b1.ToTable("Basedata_CustomerItem"); - - b1.WithOwner() - .HasForeignKey("CustomerItemId"); - }); - - b.Navigation("CustomerPackQty"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemGuideBookId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemGuideBookId"); - - b1.ToTable("Basedata_ItemGuideBook"); - - b1.WithOwner() - .HasForeignKey("ItemGuideBookId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PackQty", b1 => - { - b1.Property("ItemPackId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemPackId"); - - b1.ToTable("Basedata_ItemPack"); - - b1.WithOwner() - .HasForeignKey("ItemPackId"); - }); - - b.Navigation("PackQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.LocationSwitch", "LocSwitch", b1 => - { - b1.Property("LocationId") - .HasColumnType("uniqueidentifier"); - - b1.Property("EnableBreakStore") - .HasColumnType("bit"); - - b1.Property("EnableKeepZero") - .HasColumnType("bit"); - - b1.Property("EnableMixItem") - .HasColumnType("bit"); - - b1.Property("EnableMixLot") - .HasColumnType("bit"); - - b1.Property("EnableMixStatus") - .HasColumnType("bit"); - - b1.Property("EnableNegative") - .HasColumnType("bit"); - - b1.Property("EnableOpportunityCount") - .HasColumnType("bit"); - - b1.Property("EnableOverPick") - .HasColumnType("bit"); - - b1.Property("EnablePick") - .HasColumnType("bit"); - - b1.Property("EnableReceive") - .HasColumnType("bit"); - - b1.Property("EnableReturnFromCustomer") - .HasColumnType("bit"); - - b1.Property("EnableReturnToSupplier") - .HasColumnType("bit"); - - b1.Property("EnableShip") - .HasColumnType("bit"); - - b1.Property("EnableSplitBox") - .HasColumnType("bit"); - - b1.Property("EnableSplitPallet") - .HasColumnType("bit"); - - b1.Property("EnableWholeStore") - .HasColumnType("bit"); - - b1.HasKey("LocationId"); - - b1.ToTable("Basedata_Location"); - - b1.WithOwner() - .HasForeignKey("LocationId"); - }); - - b.Navigation("LocSwitch"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.LocationSwitch", "LocSwitch", b1 => - { - b1.Property("LocationGroupId") - .HasColumnType("uniqueidentifier"); - - b1.Property("EnableBreakStore") - .HasColumnType("bit"); - - b1.Property("EnableKeepZero") - .HasColumnType("bit"); - - b1.Property("EnableMixItem") - .HasColumnType("bit"); - - b1.Property("EnableMixLot") - .HasColumnType("bit"); - - b1.Property("EnableMixStatus") - .HasColumnType("bit"); - - b1.Property("EnableNegative") - .HasColumnType("bit"); - - b1.Property("EnableOpportunityCount") - .HasColumnType("bit"); - - b1.Property("EnableOverPick") - .HasColumnType("bit"); - - b1.Property("EnablePick") - .HasColumnType("bit"); - - b1.Property("EnableReceive") - .HasColumnType("bit"); - - b1.Property("EnableReturnFromCustomer") - .HasColumnType("bit"); - - b1.Property("EnableReturnToSupplier") - .HasColumnType("bit"); - - b1.Property("EnableShip") - .HasColumnType("bit"); - - b1.Property("EnableSplitBox") - .HasColumnType("bit"); - - b1.Property("EnableSplitPallet") - .HasColumnType("bit"); - - b1.Property("EnableWholeStore") - .HasColumnType("bit"); - - b1.HasKey("LocationGroupId"); - - b1.ToTable("Basedata_LocationGroup"); - - b1.WithOwner() - .HasForeignKey("LocationGroupId"); - }); - - b.Navigation("LocSwitch"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.ProductionLine", "ProdLineAggregateRoot") - .WithMany() - .HasForeignKey("ProdLineAggregateRootId"); - - b.HasOne("Win_in.Sfs.Basedata.Domain.WorkStation", "WorkStationAggregateRoot") - .WithMany() - .HasForeignKey("WorkStationId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.Navigation("ProdLineAggregateRoot"); - - b.Navigation("WorkStationAggregateRoot"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("ProjectId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("ProjectId"); - - b1.ToTable("Basedata_Project"); - - b1.WithOwner() - .HasForeignKey("ProjectId"); - }); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("ShiftId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("ShiftId"); - - b1.ToTable("Basedata_Shift"); - - b1.WithOwner() - .HasForeignKey("ShiftId"); - }); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "SupplierPackQty", b1 => - { - b1.Property("SupplierItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierItemId"); - - b1.ToTable("Basedata_SupplierItem"); - - b1.WithOwner() - .HasForeignKey("SupplierItemId"); - }); - - b.Navigation("SupplierPackQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103025940_Init20230103.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103025940_Init20230103.cs deleted file mode 100644 index e9ed910b5..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103025940_Init20230103.cs +++ /dev/null @@ -1,1967 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -namespace Win_in.Sfs.Basedata.Migrations; - -public partial class Init20230103 : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.CreateTable( - name: "Basedata_AQL", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - AbcClass = table.Column(type: "nvarchar(max)", nullable: true), - FloorQty = table.Column(type: "decimal(18,6)", nullable: false), - CeilingQty = table.Column(type: "decimal(18,6)", nullable: false), - SamplePercent = table.Column(type: "decimal(18,6)", nullable: false), - SampleQty = table.Column(type: "decimal(18,6)", nullable: false), - IsUsePercent = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_AQL", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Area", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - AreaType = table.Column(type: "int", nullable: false), - IsFunctional = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Area", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_AreaItem", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - AreaId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - ItemId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - UomId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - Allowed = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_AreaItem", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Bom", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Product = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Component = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - PerQty_Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PerQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - TimeRange_BeginTime = table.Column(type: "datetime2", nullable: true), - TimeRange_EndTime = table.Column(type: "datetime2", nullable: true), - ERPOp = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Layer = table.Column(type: "int", maxLength: 64, nullable: false, defaultValue: 1), - MFGOp = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DistributionType = table.Column(type: "int", nullable: false), - TruncType = table.Column(type: "int", nullable: false), - PlannedSplitRule = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Bom", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Calendar", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Module = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - TimeRange_BeginTime = table.Column(type: "datetime2", nullable: false), - TimeRange_EndTime = table.Column(type: "datetime2", nullable: false), - Status = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Calendar", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Category", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Category", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Company", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FullName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Logo = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PrimaryProduct = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Company", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Configuration", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Key = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Value = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Configuration", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Currency", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - IsBasicCurrency = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Currency", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_CurrencyExchange", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CurrencyId = table.Column(type: "uniqueidentifier", nullable: false), - BasicCurrencyId = table.Column(type: "uniqueidentifier", nullable: false), - Rate = table.Column(type: "decimal(18,6)", nullable: false), - EfficetiveTime = table.Column(type: "datetime2", nullable: false), - ExpireTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_CurrencyExchange", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Customer", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ShortName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Address = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Country = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - City = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Phone = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Fax = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PostID = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Contacts = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Currency = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsActive = table.Column(type: "bit", nullable: false), - Type = table.Column(type: "int", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Customer", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_CustomerAddress", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Address = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Contact = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - City = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Desc = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_CustomerAddress", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_CustomerBom", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CustomerId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - ParentItemId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - ChildItemId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - Qty = table.Column(type: "decimal(18,6)", nullable: false), - EffectiveTime = table.Column(type: "datetime2", nullable: false), - FailureTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_CustomerBom", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_CustomerItem", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CustomerItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Version = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - CustomerPackQty_Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CustomerPackQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - TimeRange_BeginTime = table.Column(type: "datetime2", nullable: true), - TimeRange_EndTime = table.Column(type: "datetime2", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_CustomerItem", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Dict", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Dict", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Dock", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DefaultLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Dock", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_DocumentSetting", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - TransactionType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - NumberPrefix = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - NumberFormat = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - NumberSerialLength = table.Column(type: "int", nullable: false), - NumberSeparator = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_DocumentSetting", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ErpLocation", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ErpLocation", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_InterfaceCalendar", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Year = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Month = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - BeginTime = table.Column(type: "datetime2", nullable: false), - EndTime = table.Column(type: "datetime2", nullable: false), - ConvertToTime = table.Column(type: "datetime2", nullable: false), - Description = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", nullable: true), - Company = table.Column(type: "nvarchar(450)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_InterfaceCalendar", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_InventoryRoute", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_InventoryRoute", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ItemBasic", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Desc1 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Desc2 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Status = table.Column(type: "int", nullable: false), - CanMake = table.Column(type: "bit", nullable: false), - CanBuy = table.Column(type: "bit", nullable: false), - CanOutsourcing = table.Column(type: "bit", nullable: false), - IsRecycled = table.Column(type: "bit", nullable: false), - Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Category = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Group = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Color = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Configuration = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - BasicUom = table.Column(type: "nvarchar(max)", nullable: true), - AbcClass = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ProductLine = table.Column(type: "nvarchar(max)", nullable: true), - Project = table.Column(type: "nvarchar(max)", nullable: true), - Version = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Eco = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Validity = table.Column(type: "int", nullable: false), - ValidityUnit = table.Column(type: "int", nullable: false), - ManageType = table.Column(type: "int", nullable: false), - Elevel = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsPhantom = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ItemBasic", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ItemCategory", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CategoryCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Value = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ItemCategory", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ItemGuideBook", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Item_Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Step = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - PictureBlobName = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ItemGuideBook", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ItemPack", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PackCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - PackName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PackType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - PackQty_Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PackQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - IsStdPack = table.Column(type: "bit", maxLength: 64, nullable: false), - StdPackCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ConversionRate = table.Column(type: "decimal(18,6)", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ItemPack", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ItemQuality", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Status = table.Column(type: "int", nullable: false, defaultValue: 1), - Description = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - InspectType = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ItemQuality", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ItemSafetyStock", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StoreRelationType = table.Column(type: "int", nullable: false), - StoreValue = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - MaxStock = table.Column(type: "decimal(18,6)", nullable: false), - MinStock = table.Column(type: "decimal(18,6)", nullable: false), - SafetyStock = table.Column(type: "decimal(18,6)", nullable: false), - FeedLine = table.Column(type: "decimal(18,6)", nullable: false), - FeedQty = table.Column(type: "decimal(18,6)", nullable: false), - FeedUM = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ItemSafetyStock", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ItemStoreRelation", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StoreRelationType = table.Column(type: "int", nullable: false), - StoreValue = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Enabled = table.Column(type: "bit", nullable: false), - StoreUM = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - UmQty = table.Column(type: "decimal(18,6)", nullable: false), - AltUm = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AltUmQty = table.Column(type: "decimal(18,6)", nullable: false), - PramaryUM = table.Column(type: "int", nullable: false), - IsFixed = table.Column(type: "bit", nullable: false), - MultiLoc = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ItemStoreRelation", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Location", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Type = table.Column(type: "int", nullable: false), - ErpLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - AreaCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ShelfCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RowCode = table.Column(type: "int", nullable: false, defaultValue: 1), - ColumnCode = table.Column(type: "int", nullable: false, defaultValue: 1), - DefaultInventoryStatus = table.Column(type: "int", nullable: false), - PickPriority = table.Column(type: "int", nullable: false, defaultValue: 0), - PickOrder = table.Column(type: "int", nullable: false, defaultValue: 0), - LocSwitch_EnableMixItem = table.Column(type: "bit", nullable: true), - LocSwitch_EnableMixLot = table.Column(type: "bit", nullable: true), - LocSwitch_EnableMixStatus = table.Column(type: "bit", nullable: true), - LocSwitch_EnableNegative = table.Column(type: "bit", nullable: true), - LocSwitch_EnableKeepZero = table.Column(type: "bit", nullable: true), - LocSwitch_EnableOpportunityCount = table.Column(type: "bit", nullable: true), - LocSwitch_EnablePick = table.Column(type: "bit", nullable: true), - LocSwitch_EnableOverPick = table.Column(type: "bit", nullable: true), - LocSwitch_EnableWholeStore = table.Column(type: "bit", nullable: true), - LocSwitch_EnableBreakStore = table.Column(type: "bit", nullable: true), - LocSwitch_EnableShip = table.Column(type: "bit", nullable: true), - LocSwitch_EnableReceive = table.Column(type: "bit", nullable: true), - LocSwitch_EnableReturnToSupplier = table.Column(type: "bit", nullable: true), - LocSwitch_EnableReturnFromCustomer = table.Column(type: "bit", nullable: true), - LocSwitch_EnableSplitBox = table.Column(type: "bit", nullable: true), - LocSwitch_EnableSplitPallet = table.Column(type: "bit", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Location", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_LocationGroup", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - AreaCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - GroupType = table.Column(type: "int", nullable: false), - DefaultInventoryStatus = table.Column(type: "int", nullable: false), - PickPriority = table.Column(type: "int", nullable: false, defaultValue: 0), - OverflowLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocSwitch_EnableMixItem = table.Column(type: "bit", nullable: true), - LocSwitch_EnableMixLot = table.Column(type: "bit", nullable: true), - LocSwitch_EnableMixStatus = table.Column(type: "bit", nullable: true), - LocSwitch_EnableNegative = table.Column(type: "bit", nullable: true), - LocSwitch_EnableKeepZero = table.Column(type: "bit", nullable: true), - LocSwitch_EnableOpportunityCount = table.Column(type: "bit", nullable: true), - LocSwitch_EnablePick = table.Column(type: "bit", nullable: true), - LocSwitch_EnableOverPick = table.Column(type: "bit", nullable: true), - LocSwitch_EnableWholeStore = table.Column(type: "bit", nullable: true), - LocSwitch_EnableBreakStore = table.Column(type: "bit", nullable: true), - LocSwitch_EnableShip = table.Column(type: "bit", nullable: true), - LocSwitch_EnableReceive = table.Column(type: "bit", nullable: true), - LocSwitch_EnableReturnToSupplier = table.Column(type: "bit", nullable: true), - LocSwitch_EnableReturnFromCustomer = table.Column(type: "bit", nullable: true), - LocSwitch_EnableSplitBox = table.Column(type: "bit", nullable: true), - LocSwitch_EnableSplitPallet = table.Column(type: "bit", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_LocationGroup", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Param", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Value = table.Column(type: "nvarchar(max)", nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Enabled = table.Column(type: "bit", nullable: false), - Group = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Param", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ProdLineItem", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ProdLineCode = table.Column(type: "nvarchar(450)", nullable: false), - ItemCode = table.Column(type: "nvarchar(450)", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ProdLineItem", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ProductionLine", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Type = table.Column(type: "int", nullable: false), - WorkshopCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RawLocation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductLocation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RawLocationGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ProductionLine", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Project", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - TimeRange_BeginTime = table.Column(type: "datetime2", nullable: true), - TimeRange_EndTime = table.Column(type: "datetime2", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Project", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_PurchasePriceSheet", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - SupplierId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - CurrencyId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_PurchasePriceSheet", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Route", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Route", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Rule", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: false), - Value = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Rule", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_SalePriceSheet", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CustomerId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - CurrencyId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_SalePriceSheet", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Shift", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - TimeRange_BeginTime = table.Column(type: "datetime2", nullable: true), - TimeRange_EndTime = table.Column(type: "datetime2", nullable: true), - EndAtNextDay = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Shift", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_StdCostPriceSheet", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierId = table.Column(type: "uniqueidentifier", nullable: false), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - CurrencyId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_StdCostPriceSheet", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Strategy", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Type = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Strategy", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_StrategyRule", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - StrategyId = table.Column(type: "uniqueidentifier", nullable: false), - Seq = table.Column(type: "int", nullable: false), - RuleId = table.Column(type: "uniqueidentifier", nullable: false), - EffectiveTime = table.Column(type: "datetime2", nullable: false), - ExpireTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_StrategyRule", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Supplier", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ShortName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Address = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Country = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - City = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Phone = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Fax = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PostID = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Contacts = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Bank = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Currency = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - TaxRate = table.Column(type: "decimal(18,6)", nullable: false), - IsActive = table.Column(type: "bit", nullable: false, defaultValue: true), - Type = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Supplier", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_SupplierItem", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierSimpleName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Version = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierPackQty_Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierPackQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - QtyPerPallet = table.Column(type: "decimal(18,6)", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_SupplierItem", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_SupplierTime", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - TimeSlot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Week = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_SupplierTime", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Team", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Members = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Team", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_TransactionType", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - TransType = table.Column(type: "int", nullable: false), - TransSubType = table.Column(type: "int", nullable: false), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: false), - InLocationTypes = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - OutLocationTypes = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - InLocationAreas = table.Column(type: "nvarchar(max)", nullable: true), - OutLocationAreas = table.Column(type: "nvarchar(max)", nullable: true), - ItemStatuses = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemTypes = table.Column(type: "nvarchar(max)", nullable: true), - InInventoryStatuses = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - OutInventoryStatuses = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AutoSubmitRequest = table.Column(type: "bit", nullable: false), - AutoAgreeRequest = table.Column(type: "bit", nullable: false), - AutoHandleRequest = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - Enabled = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_TransactionType", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Uom", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Description = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Type = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Uom", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Warehouse", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Warehouse", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_WorkGroup", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_WorkGroup", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_WorkShop", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_WorkShop", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_WorkStation", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ProductionLineCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - RawLocation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductLocation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Type = table.Column(type: "int", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_WorkStation", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_DictItem", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - MasterId = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Value = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Enabled = table.Column(type: "bit", nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_DictItem", x => x.Id); - table.ForeignKey( - name: "FK_Basedata_DictItem_Basedata_Dict_MasterId", - column: x => x.MasterId, - principalTable: "Basedata_Dict", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Machine", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ProdLineId = table.Column(type: "uniqueidentifier", nullable: false), - ProdLineAggregateRootId = table.Column(type: "uniqueidentifier", nullable: true), - WorkStationId = table.Column(type: "uniqueidentifier", nullable: false), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Machine", x => x.Id); - table.ForeignKey( - name: "FK_Basedata_Machine_Basedata_ProductionLine_ProdLineAggregateRootId", - column: x => x.ProdLineAggregateRootId, - principalTable: "Basedata_ProductionLine", - principalColumn: "Id", - onDelete: ReferentialAction.Restrict); - table.ForeignKey( - name: "FK_Basedata_Machine_Basedata_WorkStation_WorkStationId", - column: x => x.WorkStationId, - principalTable: "Basedata_WorkStation", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_AQL_SupplierCode_ItemCode_FloorQty_Company", - table: "Basedata_AQL", - columns: new[] { "SupplierCode", "ItemCode", "FloorQty", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Area_Code_Company", - table: "Basedata_Area", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_AreaItem_Company_AreaId_ItemId", - table: "Basedata_AreaItem", - columns: new[] { "Company", "AreaId", "ItemId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Bom_Product_Company_Component", - table: "Basedata_Bom", - columns: new[] { "Product", "Company", "Component" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Calendar_Company", - table: "Basedata_Calendar", - column: "Company", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Category_Code_Company", - table: "Basedata_Category", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Company_Code_Company", - table: "Basedata_Company", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Configuration_Company", - table: "Basedata_Configuration", - column: "Company", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Currency_Code_Company", - table: "Basedata_Currency", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CurrencyExchange_Company_CurrencyId_BasicCurrencyId", - table: "Basedata_CurrencyExchange", - columns: new[] { "Company", "CurrencyId", "BasicCurrencyId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Customer_Code_Company", - table: "Basedata_Customer", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CustomerAddress_Company_Code_CustomerCode", - table: "Basedata_CustomerAddress", - columns: new[] { "Company", "Code", "CustomerCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CustomerBom_Company_CustomerId_ParentItemId_ChildItemId", - table: "Basedata_CustomerBom", - columns: new[] { "Company", "CustomerId", "ParentItemId", "ChildItemId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CustomerItem_Company_CustomerCode_ItemCode", - table: "Basedata_CustomerItem", - columns: new[] { "Company", "CustomerCode", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Dict_Code_Company", - table: "Basedata_Dict", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_DictItem_MasterId", - table: "Basedata_DictItem", - column: "MasterId"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Dock_Code_Company", - table: "Basedata_Dock", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_DocumentSetting_Company_Code", - table: "Basedata_DocumentSetting", - columns: new[] { "Company", "Code" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ErpLocation_Code_Company", - table: "Basedata_ErpLocation", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_InterfaceCalendar_Code_Company", - table: "Basedata_InterfaceCalendar", - columns: new[] { "Code", "Company" }, - unique: true, - filter: "[Company] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_InventoryRoute_Code_Company", - table: "Basedata_InventoryRoute", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemBasic_Code_Company", - table: "Basedata_ItemBasic", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemCategory_Company_CategoryCode_ItemCode_Value", - table: "Basedata_ItemCategory", - columns: new[] { "Company", "CategoryCode", "ItemCode", "Value" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemGuideBook_ItemCode_Company", - table: "Basedata_ItemGuideBook", - columns: new[] { "ItemCode", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemPack_Company_ItemCode_PackCode", - table: "Basedata_ItemPack", - columns: new[] { "Company", "ItemCode", "PackCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemQuality_ItemCode_SupplierCode", - table: "Basedata_ItemQuality", - columns: new[] { "ItemCode", "SupplierCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemSafetyStock_ItemCode_Company_StoreRelationType_StoreValue", - table: "Basedata_ItemSafetyStock", - columns: new[] { "ItemCode", "Company", "StoreRelationType", "StoreValue" }); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemStoreRelation_ItemCode_Company_StoreRelationType_StoreValue", - table: "Basedata_ItemStoreRelation", - columns: new[] { "ItemCode", "Company", "StoreRelationType", "StoreValue" }, - unique: true, - filter: "[StoreValue] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Location_Code_Company", - table: "Basedata_Location", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_LocationGroup_Code_Company", - table: "Basedata_LocationGroup", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Machine_Code_Company", - table: "Basedata_Machine", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Machine_ProdLineAggregateRootId", - table: "Basedata_Machine", - column: "ProdLineAggregateRootId"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Machine_WorkStationId", - table: "Basedata_Machine", - column: "WorkStationId"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Param_Code_Company", - table: "Basedata_Param", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ProdLineItem_ProdLineCode_ItemCode_Company", - table: "Basedata_ProdLineItem", - columns: new[] { "ProdLineCode", "ItemCode", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ProductionLine_Code_Company", - table: "Basedata_ProductionLine", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Project_Code_Company", - table: "Basedata_Project", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_PurchasePriceSheet_Code_Company", - table: "Basedata_PurchasePriceSheet", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Route_Code_Company", - table: "Basedata_Route", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Rule_Code_Company", - table: "Basedata_Rule", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SalePriceSheet_Code_Company_CustomerId", - table: "Basedata_SalePriceSheet", - columns: new[] { "Code", "Company", "CustomerId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Shift_Code_Company", - table: "Basedata_Shift", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_StdCostPriceSheet_Code_Company_SupplierId", - table: "Basedata_StdCostPriceSheet", - columns: new[] { "Code", "Company", "SupplierId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Strategy_Code_Company", - table: "Basedata_Strategy", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_StrategyRule_StrategyId_RuleId_Company", - table: "Basedata_StrategyRule", - columns: new[] { "StrategyId", "RuleId", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Supplier_Code_Company", - table: "Basedata_Supplier", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SupplierItem_SupplierCode_ItemCode_Company", - table: "Basedata_SupplierItem", - columns: new[] { "SupplierCode", "ItemCode", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SupplierTime_SupplierCode_Company_TimeSlot_Week", - table: "Basedata_SupplierTime", - columns: new[] { "SupplierCode", "Company", "TimeSlot", "Week" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Team_Code_Company", - table: "Basedata_Team", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_TransactionType_TransType_TransSubType_Company", - table: "Basedata_TransactionType", - columns: new[] { "TransType", "TransSubType", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Uom_Code_Company", - table: "Basedata_Uom", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Warehouse_Code_Company", - table: "Basedata_Warehouse", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_WorkGroup_Code_Company", - table: "Basedata_WorkGroup", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_WorkShop_Code_Company", - table: "Basedata_WorkShop", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_WorkStation_Code_Company", - table: "Basedata_WorkStation", - columns: new[] { "Code", "Company" }, - unique: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropTable( - name: "Basedata_AQL"); - - migrationBuilder.DropTable( - name: "Basedata_Area"); - - migrationBuilder.DropTable( - name: "Basedata_AreaItem"); - - migrationBuilder.DropTable( - name: "Basedata_Bom"); - - migrationBuilder.DropTable( - name: "Basedata_Calendar"); - - migrationBuilder.DropTable( - name: "Basedata_Category"); - - migrationBuilder.DropTable( - name: "Basedata_Company"); - - migrationBuilder.DropTable( - name: "Basedata_Configuration"); - - migrationBuilder.DropTable( - name: "Basedata_Currency"); - - migrationBuilder.DropTable( - name: "Basedata_CurrencyExchange"); - - migrationBuilder.DropTable( - name: "Basedata_Customer"); - - migrationBuilder.DropTable( - name: "Basedata_CustomerAddress"); - - migrationBuilder.DropTable( - name: "Basedata_CustomerBom"); - - migrationBuilder.DropTable( - name: "Basedata_CustomerItem"); - - migrationBuilder.DropTable( - name: "Basedata_DictItem"); - - migrationBuilder.DropTable( - name: "Basedata_Dock"); - - migrationBuilder.DropTable( - name: "Basedata_DocumentSetting"); - - migrationBuilder.DropTable( - name: "Basedata_ErpLocation"); - - migrationBuilder.DropTable( - name: "Basedata_InterfaceCalendar"); - - migrationBuilder.DropTable( - name: "Basedata_InventoryRoute"); - - migrationBuilder.DropTable( - name: "Basedata_ItemBasic"); - - migrationBuilder.DropTable( - name: "Basedata_ItemCategory"); - - migrationBuilder.DropTable( - name: "Basedata_ItemGuideBook"); - - migrationBuilder.DropTable( - name: "Basedata_ItemPack"); - - migrationBuilder.DropTable( - name: "Basedata_ItemQuality"); - - migrationBuilder.DropTable( - name: "Basedata_ItemSafetyStock"); - - migrationBuilder.DropTable( - name: "Basedata_ItemStoreRelation"); - - migrationBuilder.DropTable( - name: "Basedata_Location"); - - migrationBuilder.DropTable( - name: "Basedata_LocationGroup"); - - migrationBuilder.DropTable( - name: "Basedata_Machine"); - - migrationBuilder.DropTable( - name: "Basedata_Param"); - - migrationBuilder.DropTable( - name: "Basedata_ProdLineItem"); - - migrationBuilder.DropTable( - name: "Basedata_Project"); - - migrationBuilder.DropTable( - name: "Basedata_PurchasePriceSheet"); - - migrationBuilder.DropTable( - name: "Basedata_Route"); - - migrationBuilder.DropTable( - name: "Basedata_Rule"); - - migrationBuilder.DropTable( - name: "Basedata_SalePriceSheet"); - - migrationBuilder.DropTable( - name: "Basedata_Shift"); - - migrationBuilder.DropTable( - name: "Basedata_StdCostPriceSheet"); - - migrationBuilder.DropTable( - name: "Basedata_Strategy"); - - migrationBuilder.DropTable( - name: "Basedata_StrategyRule"); - - migrationBuilder.DropTable( - name: "Basedata_Supplier"); - - migrationBuilder.DropTable( - name: "Basedata_SupplierItem"); - - migrationBuilder.DropTable( - name: "Basedata_SupplierTime"); - - migrationBuilder.DropTable( - name: "Basedata_Team"); - - migrationBuilder.DropTable( - name: "Basedata_TransactionType"); - - migrationBuilder.DropTable( - name: "Basedata_Uom"); - - migrationBuilder.DropTable( - name: "Basedata_Warehouse"); - - migrationBuilder.DropTable( - name: "Basedata_WorkGroup"); - - migrationBuilder.DropTable( - name: "Basedata_WorkShop"); - - migrationBuilder.DropTable( - name: "Basedata_Dict"); - - migrationBuilder.DropTable( - name: "Basedata_ProductionLine"); - - migrationBuilder.DropTable( - name: "Basedata_WorkStation"); - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103031911_ItemSafetyStockModifyIndexToUnique.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103031911_ItemSafetyStockModifyIndexToUnique.Designer.cs deleted file mode 100644 index cf3893593..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103031911_ItemSafetyStockModifyIndexToUnique.Designer.cs +++ /dev/null @@ -1,4650 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - [Migration("20230103031911_ItemSafetyStockModifyIndexToUnique")] - partial class ItemSafetyStockModifyIndexToUnique - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("Relational:MaxIdentifierLength", 128) - .HasAnnotation("ProductVersion", "5.0.17") - .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty", "Company") - .IsUnique(); - - b.ToTable("Basedata_AQL"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .HasColumnType("int"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Area"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AreaItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Allowed") - .HasColumnType("bit"); - - b.Property("AreaId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UomId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Company", "AreaId", "ItemId") - .IsUnique(); - - b.ToTable("Basedata_AreaItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .HasColumnType("int"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .HasColumnType("int"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Company", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company") - .IsUnique(); - - b.ToTable("Basedata_Calendar"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Category"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Company", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FullName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Logo") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PrimaryProduct") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Company"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Configuration", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Key") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Company") - .IsUnique(); - - b.ToTable("Basedata_Configuration"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Currency"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Customer"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerBom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ChildItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FailureTime") - .HasColumnType("datetime2"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ParentItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CustomerId", "ParentItemId", "ChildItemId") - .IsUnique(); - - b.ToTable("Basedata_CustomerBom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Dict"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Dock"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .HasColumnType("nvarchar(450)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique() - .HasFilter("[Company] IS NOT NULL"); - - b.ToTable("Basedata_InterfaceCalendar"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InventoryRoute", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_InventoryRoute"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .HasColumnType("int"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLine") - .HasColumnType("nvarchar(max)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .HasColumnType("int"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CategoryCode", "ItemCode", "Value") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "Company") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConversionRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsStdPack") - .HasMaxLength(64) - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company", "ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "Company", "WarehouseCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemSafetyStock"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "Company", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineAggregateRootId") - .HasColumnType("uniqueidentifier"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineAggregateRootId"); - - b.HasIndex("WorkStationId"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Machine"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Param", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Param"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProdLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode", "Company") - .IsUnique(); - - b.ToTable("Basedata_ProdLineItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Project"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Route", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Route"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Rule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Rule"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Shift"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Strategy", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Strategy"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StrategyRule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RuleId") - .HasColumnType("uniqueidentifier"); - - b.Property("Seq") - .HasColumnType("int"); - - b.Property("StrategyId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("StrategyId", "RuleId", "Company") - .IsUnique(); - - b.ToTable("Basedata_StrategyRule"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Supplier"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "Company") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTime", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "Company", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTime"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Team"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .HasColumnType("int"); - - b.Property("TransType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType", "Company") - .IsUnique(); - - b.ToTable("Basedata_TransactionType"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Uom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Warehouse"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_WorkShop"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_WorkStation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("BomId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("BomId"); - - b1.ToTable("Basedata_Bom"); - - b1.WithOwner() - .HasForeignKey("BomId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PerQty", b1 => - { - b1.Property("BomId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BomId"); - - b1.ToTable("Basedata_Bom"); - - b1.WithOwner() - .HasForeignKey("BomId"); - }); - - b.Navigation("PerQty"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CalendarId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CalendarId"); - - b1.ToTable("Basedata_Calendar"); - - b1.WithOwner() - .HasForeignKey("CalendarId"); - }); - - b.Navigation("TimeRange") - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CustomerItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CustomerItemId"); - - b1.ToTable("Basedata_CustomerItem"); - - b1.WithOwner() - .HasForeignKey("CustomerItemId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "CustomerPackQty", b1 => - { - b1.Property("CustomerItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerItemId"); - - b1.ToTable("Basedata_CustomerItem"); - - b1.WithOwner() - .HasForeignKey("CustomerItemId"); - }); - - b.Navigation("CustomerPackQty"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemGuideBookId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemGuideBookId"); - - b1.ToTable("Basedata_ItemGuideBook"); - - b1.WithOwner() - .HasForeignKey("ItemGuideBookId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PackQty", b1 => - { - b1.Property("ItemPackId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemPackId"); - - b1.ToTable("Basedata_ItemPack"); - - b1.WithOwner() - .HasForeignKey("ItemPackId"); - }); - - b.Navigation("PackQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.LocationSwitch", "LocSwitch", b1 => - { - b1.Property("LocationId") - .HasColumnType("uniqueidentifier"); - - b1.Property("EnableBreakStore") - .HasColumnType("bit"); - - b1.Property("EnableKeepZero") - .HasColumnType("bit"); - - b1.Property("EnableMixItem") - .HasColumnType("bit"); - - b1.Property("EnableMixLot") - .HasColumnType("bit"); - - b1.Property("EnableMixStatus") - .HasColumnType("bit"); - - b1.Property("EnableNegative") - .HasColumnType("bit"); - - b1.Property("EnableOpportunityCount") - .HasColumnType("bit"); - - b1.Property("EnableOverPick") - .HasColumnType("bit"); - - b1.Property("EnablePick") - .HasColumnType("bit"); - - b1.Property("EnableReceive") - .HasColumnType("bit"); - - b1.Property("EnableReturnFromCustomer") - .HasColumnType("bit"); - - b1.Property("EnableReturnToSupplier") - .HasColumnType("bit"); - - b1.Property("EnableShip") - .HasColumnType("bit"); - - b1.Property("EnableSplitBox") - .HasColumnType("bit"); - - b1.Property("EnableSplitPallet") - .HasColumnType("bit"); - - b1.Property("EnableWholeStore") - .HasColumnType("bit"); - - b1.HasKey("LocationId"); - - b1.ToTable("Basedata_Location"); - - b1.WithOwner() - .HasForeignKey("LocationId"); - }); - - b.Navigation("LocSwitch"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.LocationSwitch", "LocSwitch", b1 => - { - b1.Property("LocationGroupId") - .HasColumnType("uniqueidentifier"); - - b1.Property("EnableBreakStore") - .HasColumnType("bit"); - - b1.Property("EnableKeepZero") - .HasColumnType("bit"); - - b1.Property("EnableMixItem") - .HasColumnType("bit"); - - b1.Property("EnableMixLot") - .HasColumnType("bit"); - - b1.Property("EnableMixStatus") - .HasColumnType("bit"); - - b1.Property("EnableNegative") - .HasColumnType("bit"); - - b1.Property("EnableOpportunityCount") - .HasColumnType("bit"); - - b1.Property("EnableOverPick") - .HasColumnType("bit"); - - b1.Property("EnablePick") - .HasColumnType("bit"); - - b1.Property("EnableReceive") - .HasColumnType("bit"); - - b1.Property("EnableReturnFromCustomer") - .HasColumnType("bit"); - - b1.Property("EnableReturnToSupplier") - .HasColumnType("bit"); - - b1.Property("EnableShip") - .HasColumnType("bit"); - - b1.Property("EnableSplitBox") - .HasColumnType("bit"); - - b1.Property("EnableSplitPallet") - .HasColumnType("bit"); - - b1.Property("EnableWholeStore") - .HasColumnType("bit"); - - b1.HasKey("LocationGroupId"); - - b1.ToTable("Basedata_LocationGroup"); - - b1.WithOwner() - .HasForeignKey("LocationGroupId"); - }); - - b.Navigation("LocSwitch"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.ProductionLine", "ProdLineAggregateRoot") - .WithMany() - .HasForeignKey("ProdLineAggregateRootId"); - - b.HasOne("Win_in.Sfs.Basedata.Domain.WorkStation", "WorkStationAggregateRoot") - .WithMany() - .HasForeignKey("WorkStationId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.Navigation("ProdLineAggregateRoot"); - - b.Navigation("WorkStationAggregateRoot"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("ProjectId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("ProjectId"); - - b1.ToTable("Basedata_Project"); - - b1.WithOwner() - .HasForeignKey("ProjectId"); - }); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("ShiftId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("ShiftId"); - - b1.ToTable("Basedata_Shift"); - - b1.WithOwner() - .HasForeignKey("ShiftId"); - }); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "SupplierPackQty", b1 => - { - b1.Property("SupplierItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierItemId"); - - b1.ToTable("Basedata_SupplierItem"); - - b1.WithOwner() - .HasForeignKey("SupplierItemId"); - }); - - b.Navigation("SupplierPackQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103031911_ItemSafetyStockModifyIndexToUnique.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103031911_ItemSafetyStockModifyIndexToUnique.cs deleted file mode 100644 index 83e809a86..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103031911_ItemSafetyStockModifyIndexToUnique.cs +++ /dev/null @@ -1,32 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -namespace Win_in.Sfs.Basedata.Migrations; - -public partial class ItemSafetyStockModifyIndexToUnique : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemSafetyStock_ItemCode_Company_StoreRelationType_StoreValue", - table: "Basedata_ItemSafetyStock"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemSafetyStock_ItemCode_Company_WarehouseCode_StoreRelationType_StoreValue", - table: "Basedata_ItemSafetyStock", - columns: new[] { "ItemCode", "Company", "WarehouseCode", "StoreRelationType", "StoreValue" }, - unique: true, - filter: "[StoreValue] IS NOT NULL"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemSafetyStock_ItemCode_Company_WarehouseCode_StoreRelationType_StoreValue", - table: "Basedata_ItemSafetyStock"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemSafetyStock_ItemCode_Company_StoreRelationType_StoreValue", - table: "Basedata_ItemSafetyStock", - columns: new[] { "ItemCode", "Company", "StoreRelationType", "StoreValue" }); - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103035714_Modify20230103.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103035714_Modify20230103.Designer.cs deleted file mode 100644 index 59f09f5d5..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103035714_Modify20230103.Designer.cs +++ /dev/null @@ -1,4627 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - [Migration("20230103035714_Modify20230103")] - partial class Modify20230103 - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("Relational:MaxIdentifierLength", 128) - .HasAnnotation("ProductVersion", "5.0.17") - .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty", "Company") - .IsUnique(); - - b.ToTable("Basedata_AQL"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .HasColumnType("int"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Area"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AreaItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Allowed") - .HasColumnType("bit"); - - b.Property("AreaId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UomId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Company", "AreaId", "ItemId") - .IsUnique(); - - b.ToTable("Basedata_AreaItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .HasColumnType("int"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .HasColumnType("int"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Company", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company") - .IsUnique(); - - b.ToTable("Basedata_Calendar"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Category"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Company", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FullName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Logo") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PrimaryProduct") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Company"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Configuration", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Key") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Company") - .IsUnique(); - - b.ToTable("Basedata_Configuration"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Currency"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Customer"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerBom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ChildItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FailureTime") - .HasColumnType("datetime2"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ParentItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CustomerId", "ParentItemId", "ChildItemId") - .IsUnique(); - - b.ToTable("Basedata_CustomerBom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Dict"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Dock"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .HasColumnType("nvarchar(450)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique() - .HasFilter("[Company] IS NOT NULL"); - - b.ToTable("Basedata_InterfaceCalendar"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InventoryRoute", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_InventoryRoute"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .HasColumnType("int"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLine") - .HasColumnType("nvarchar(max)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .HasColumnType("int"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "CategoryCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "Company") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConversionRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsStdPack") - .HasMaxLength(64) - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Company", "ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "Company", "WarehouseCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemSafetyStock"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "Company", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Machine"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Param", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Param"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProdLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode", "Company") - .IsUnique(); - - b.ToTable("Basedata_ProdLineItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Project"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Route", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Route"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Rule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Rule"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Shift"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Strategy", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Strategy"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StrategyRule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RuleId") - .HasColumnType("uniqueidentifier"); - - b.Property("Seq") - .HasColumnType("int"); - - b.Property("StrategyId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("StrategyId", "RuleId", "Company") - .IsUnique(); - - b.ToTable("Basedata_StrategyRule"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Supplier"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "Company") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTime", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "Company", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTime"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Team"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .HasColumnType("int"); - - b.Property("TransType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType", "Company") - .IsUnique(); - - b.ToTable("Basedata_TransactionType"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Uom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_Warehouse"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_WorkShop"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code", "Company") - .IsUnique(); - - b.ToTable("Basedata_WorkStation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("BomId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("BomId"); - - b1.ToTable("Basedata_Bom"); - - b1.WithOwner() - .HasForeignKey("BomId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PerQty", b1 => - { - b1.Property("BomId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BomId"); - - b1.ToTable("Basedata_Bom"); - - b1.WithOwner() - .HasForeignKey("BomId"); - }); - - b.Navigation("PerQty"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CalendarId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CalendarId"); - - b1.ToTable("Basedata_Calendar"); - - b1.WithOwner() - .HasForeignKey("CalendarId"); - }); - - b.Navigation("TimeRange") - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CustomerItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CustomerItemId"); - - b1.ToTable("Basedata_CustomerItem"); - - b1.WithOwner() - .HasForeignKey("CustomerItemId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "CustomerPackQty", b1 => - { - b1.Property("CustomerItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerItemId"); - - b1.ToTable("Basedata_CustomerItem"); - - b1.WithOwner() - .HasForeignKey("CustomerItemId"); - }); - - b.Navigation("CustomerPackQty"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemGuideBookId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemGuideBookId"); - - b1.ToTable("Basedata_ItemGuideBook"); - - b1.WithOwner() - .HasForeignKey("ItemGuideBookId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PackQty", b1 => - { - b1.Property("ItemPackId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemPackId"); - - b1.ToTable("Basedata_ItemPack"); - - b1.WithOwner() - .HasForeignKey("ItemPackId"); - }); - - b.Navigation("PackQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.LocationSwitch", "LocSwitch", b1 => - { - b1.Property("LocationId") - .HasColumnType("uniqueidentifier"); - - b1.Property("EnableBreakStore") - .HasColumnType("bit"); - - b1.Property("EnableKeepZero") - .HasColumnType("bit"); - - b1.Property("EnableMixItem") - .HasColumnType("bit"); - - b1.Property("EnableMixLot") - .HasColumnType("bit"); - - b1.Property("EnableMixStatus") - .HasColumnType("bit"); - - b1.Property("EnableNegative") - .HasColumnType("bit"); - - b1.Property("EnableOpportunityCount") - .HasColumnType("bit"); - - b1.Property("EnableOverPick") - .HasColumnType("bit"); - - b1.Property("EnablePick") - .HasColumnType("bit"); - - b1.Property("EnableReceive") - .HasColumnType("bit"); - - b1.Property("EnableReturnFromCustomer") - .HasColumnType("bit"); - - b1.Property("EnableReturnToSupplier") - .HasColumnType("bit"); - - b1.Property("EnableShip") - .HasColumnType("bit"); - - b1.Property("EnableSplitBox") - .HasColumnType("bit"); - - b1.Property("EnableSplitPallet") - .HasColumnType("bit"); - - b1.Property("EnableWholeStore") - .HasColumnType("bit"); - - b1.HasKey("LocationId"); - - b1.ToTable("Basedata_Location"); - - b1.WithOwner() - .HasForeignKey("LocationId"); - }); - - b.Navigation("LocSwitch"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.LocationSwitch", "LocSwitch", b1 => - { - b1.Property("LocationGroupId") - .HasColumnType("uniqueidentifier"); - - b1.Property("EnableBreakStore") - .HasColumnType("bit"); - - b1.Property("EnableKeepZero") - .HasColumnType("bit"); - - b1.Property("EnableMixItem") - .HasColumnType("bit"); - - b1.Property("EnableMixLot") - .HasColumnType("bit"); - - b1.Property("EnableMixStatus") - .HasColumnType("bit"); - - b1.Property("EnableNegative") - .HasColumnType("bit"); - - b1.Property("EnableOpportunityCount") - .HasColumnType("bit"); - - b1.Property("EnableOverPick") - .HasColumnType("bit"); - - b1.Property("EnablePick") - .HasColumnType("bit"); - - b1.Property("EnableReceive") - .HasColumnType("bit"); - - b1.Property("EnableReturnFromCustomer") - .HasColumnType("bit"); - - b1.Property("EnableReturnToSupplier") - .HasColumnType("bit"); - - b1.Property("EnableShip") - .HasColumnType("bit"); - - b1.Property("EnableSplitBox") - .HasColumnType("bit"); - - b1.Property("EnableSplitPallet") - .HasColumnType("bit"); - - b1.Property("EnableWholeStore") - .HasColumnType("bit"); - - b1.HasKey("LocationGroupId"); - - b1.ToTable("Basedata_LocationGroup"); - - b1.WithOwner() - .HasForeignKey("LocationGroupId"); - }); - - b.Navigation("LocSwitch"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("ProjectId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("ProjectId"); - - b1.ToTable("Basedata_Project"); - - b1.WithOwner() - .HasForeignKey("ProjectId"); - }); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("ShiftId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("ShiftId"); - - b1.ToTable("Basedata_Shift"); - - b1.WithOwner() - .HasForeignKey("ShiftId"); - }); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "SupplierPackQty", b1 => - { - b1.Property("SupplierItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierItemId"); - - b1.ToTable("Basedata_SupplierItem"); - - b1.WithOwner() - .HasForeignKey("SupplierItemId"); - }); - - b.Navigation("SupplierPackQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103035714_Modify20230103.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103035714_Modify20230103.cs deleted file mode 100644 index b7dfbd094..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230103035714_Modify20230103.cs +++ /dev/null @@ -1,105 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -namespace Win_in.Sfs.Basedata.Migrations; - -public partial class Modify20230103 : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropForeignKey( - name: "FK_Basedata_Machine_Basedata_ProductionLine_ProdLineAggregateRootId", - table: "Basedata_Machine"); - - migrationBuilder.DropForeignKey( - name: "FK_Basedata_Machine_Basedata_WorkStation_WorkStationId", - table: "Basedata_Machine"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Machine_ProdLineAggregateRootId", - table: "Basedata_Machine"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Machine_WorkStationId", - table: "Basedata_Machine"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemCategory_Company_CategoryCode_ItemCode_Value", - table: "Basedata_ItemCategory"); - - migrationBuilder.DropColumn( - name: "ProdLineAggregateRootId", - table: "Basedata_Machine"); - - migrationBuilder.AlterColumn( - name: "ItemTypes", - table: "Basedata_TransactionType", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemCategory_Company_CategoryCode_ItemCode", - table: "Basedata_ItemCategory", - columns: new[] { "Company", "CategoryCode", "ItemCode" }, - unique: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemCategory_Company_CategoryCode_ItemCode", - table: "Basedata_ItemCategory"); - - migrationBuilder.AlterColumn( - name: "ItemTypes", - table: "Basedata_TransactionType", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ProdLineAggregateRootId", - table: "Basedata_Machine", - type: "uniqueidentifier", - nullable: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Machine_ProdLineAggregateRootId", - table: "Basedata_Machine", - column: "ProdLineAggregateRootId"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Machine_WorkStationId", - table: "Basedata_Machine", - column: "WorkStationId"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemCategory_Company_CategoryCode_ItemCode_Value", - table: "Basedata_ItemCategory", - columns: new[] { "Company", "CategoryCode", "ItemCode", "Value" }, - unique: true); - - migrationBuilder.AddForeignKey( - name: "FK_Basedata_Machine_Basedata_ProductionLine_ProdLineAggregateRootId", - table: "Basedata_Machine", - column: "ProdLineAggregateRootId", - principalTable: "Basedata_ProductionLine", - principalColumn: "Id", - onDelete: ReferentialAction.Restrict); - - migrationBuilder.AddForeignKey( - name: "FK_Basedata_Machine_Basedata_WorkStation_WorkStationId", - table: "Basedata_Machine", - column: "WorkStationId", - principalTable: "Basedata_WorkStation", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230104024643_RemoveCompany.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230104024643_RemoveCompany.Designer.cs deleted file mode 100644 index fb804b8c6..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230104024643_RemoveCompany.Designer.cs +++ /dev/null @@ -1,4242 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - [Migration("20230104024643_RemoveCompany")] - partial class RemoveCompany - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("Relational:MaxIdentifierLength", 128) - .HasAnnotation("ProductVersion", "5.0.17") - .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty") - .IsUnique(); - - b.ToTable("Basedata_AQL"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .HasColumnType("int"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Area"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AreaItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Allowed") - .HasColumnType("bit"); - - b.Property("AreaId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UomId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("AreaId", "ItemId") - .IsUnique(); - - b.ToTable("Basedata_AreaItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .HasColumnType("int"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .HasColumnType("int"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Module") - .IsUnique(); - - b.ToTable("Basedata_Calendar"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Category"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Configuration", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Key") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Key") - .IsUnique(); - - b.ToTable("Basedata_Configuration"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Currency"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Customer"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerBom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ChildItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FailureTime") - .HasColumnType("datetime2"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ParentItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CustomerId", "ParentItemId", "ChildItemId") - .IsUnique(); - - b.ToTable("Basedata_CustomerBom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dict"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dock"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InterfaceCalendar"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InventoryRoute", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InventoryRoute"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .HasColumnType("int"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLine") - .HasColumnType("nvarchar(max)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .HasColumnType("int"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CategoryCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConversionRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsStdPack") - .HasMaxLength(64) - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "WarehouseCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemSafetyStock"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Machine"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Param", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Param"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProdLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ProdLineItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Project"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Route", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Route"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Rule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Rule"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Shift"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Strategy", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Strategy"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StrategyRule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RuleId") - .HasColumnType("uniqueidentifier"); - - b.Property("Seq") - .HasColumnType("int"); - - b.Property("StrategyId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("StrategyId", "RuleId") - .IsUnique(); - - b.ToTable("Basedata_StrategyRule"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Supplier"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTime", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTime"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Team"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .HasColumnType("int"); - - b.Property("TransType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType") - .IsUnique(); - - b.ToTable("Basedata_TransactionType"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Uom"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Warehouse"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkShop"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkStation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("BomId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("BomId"); - - b1.ToTable("Basedata_Bom"); - - b1.WithOwner() - .HasForeignKey("BomId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PerQty", b1 => - { - b1.Property("BomId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BomId"); - - b1.ToTable("Basedata_Bom"); - - b1.WithOwner() - .HasForeignKey("BomId"); - }); - - b.Navigation("PerQty"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CalendarId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CalendarId"); - - b1.ToTable("Basedata_Calendar"); - - b1.WithOwner() - .HasForeignKey("CalendarId"); - }); - - b.Navigation("TimeRange") - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CustomerItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CustomerItemId"); - - b1.ToTable("Basedata_CustomerItem"); - - b1.WithOwner() - .HasForeignKey("CustomerItemId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "CustomerPackQty", b1 => - { - b1.Property("CustomerItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerItemId"); - - b1.ToTable("Basedata_CustomerItem"); - - b1.WithOwner() - .HasForeignKey("CustomerItemId"); - }); - - b.Navigation("CustomerPackQty"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemGuideBookId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemGuideBookId"); - - b1.ToTable("Basedata_ItemGuideBook"); - - b1.WithOwner() - .HasForeignKey("ItemGuideBookId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PackQty", b1 => - { - b1.Property("ItemPackId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemPackId"); - - b1.ToTable("Basedata_ItemPack"); - - b1.WithOwner() - .HasForeignKey("ItemPackId"); - }); - - b.Navigation("PackQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.LocationSwitch", "LocSwitch", b1 => - { - b1.Property("LocationId") - .HasColumnType("uniqueidentifier"); - - b1.Property("EnableBreakStore") - .HasColumnType("bit"); - - b1.Property("EnableKeepZero") - .HasColumnType("bit"); - - b1.Property("EnableMixItem") - .HasColumnType("bit"); - - b1.Property("EnableMixLot") - .HasColumnType("bit"); - - b1.Property("EnableMixStatus") - .HasColumnType("bit"); - - b1.Property("EnableNegative") - .HasColumnType("bit"); - - b1.Property("EnableOpportunityCount") - .HasColumnType("bit"); - - b1.Property("EnableOverPick") - .HasColumnType("bit"); - - b1.Property("EnablePick") - .HasColumnType("bit"); - - b1.Property("EnableReceive") - .HasColumnType("bit"); - - b1.Property("EnableReturnFromCustomer") - .HasColumnType("bit"); - - b1.Property("EnableReturnToSupplier") - .HasColumnType("bit"); - - b1.Property("EnableShip") - .HasColumnType("bit"); - - b1.Property("EnableSplitBox") - .HasColumnType("bit"); - - b1.Property("EnableSplitPallet") - .HasColumnType("bit"); - - b1.Property("EnableWholeStore") - .HasColumnType("bit"); - - b1.HasKey("LocationId"); - - b1.ToTable("Basedata_Location"); - - b1.WithOwner() - .HasForeignKey("LocationId"); - }); - - b.Navigation("LocSwitch"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.LocationSwitch", "LocSwitch", b1 => - { - b1.Property("LocationGroupId") - .HasColumnType("uniqueidentifier"); - - b1.Property("EnableBreakStore") - .HasColumnType("bit"); - - b1.Property("EnableKeepZero") - .HasColumnType("bit"); - - b1.Property("EnableMixItem") - .HasColumnType("bit"); - - b1.Property("EnableMixLot") - .HasColumnType("bit"); - - b1.Property("EnableMixStatus") - .HasColumnType("bit"); - - b1.Property("EnableNegative") - .HasColumnType("bit"); - - b1.Property("EnableOpportunityCount") - .HasColumnType("bit"); - - b1.Property("EnableOverPick") - .HasColumnType("bit"); - - b1.Property("EnablePick") - .HasColumnType("bit"); - - b1.Property("EnableReceive") - .HasColumnType("bit"); - - b1.Property("EnableReturnFromCustomer") - .HasColumnType("bit"); - - b1.Property("EnableReturnToSupplier") - .HasColumnType("bit"); - - b1.Property("EnableShip") - .HasColumnType("bit"); - - b1.Property("EnableSplitBox") - .HasColumnType("bit"); - - b1.Property("EnableSplitPallet") - .HasColumnType("bit"); - - b1.Property("EnableWholeStore") - .HasColumnType("bit"); - - b1.HasKey("LocationGroupId"); - - b1.ToTable("Basedata_LocationGroup"); - - b1.WithOwner() - .HasForeignKey("LocationGroupId"); - }); - - b.Navigation("LocSwitch"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("ProjectId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("ProjectId"); - - b1.ToTable("Basedata_Project"); - - b1.WithOwner() - .HasForeignKey("ProjectId"); - }); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("ShiftId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("ShiftId"); - - b1.ToTable("Basedata_Shift"); - - b1.WithOwner() - .HasForeignKey("ShiftId"); - }); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "SupplierPackQty", b1 => - { - b1.Property("SupplierItemId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierItemId"); - - b1.ToTable("Basedata_SupplierItem"); - - b1.WithOwner() - .HasForeignKey("SupplierItemId"); - }); - - b.Navigation("SupplierPackQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230104024643_RemoveCompany.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230104024643_RemoveCompany.cs deleted file mode 100644 index 1db1f7ee3..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230104024643_RemoveCompany.cs +++ /dev/null @@ -1,1675 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -namespace Win_in.Sfs.Basedata.Migrations; - -public partial class RemoveCompany : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropTable( - name: "Basedata_Company"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_WorkStation_Code_Company", - table: "Basedata_WorkStation"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_WorkShop_Code_Company", - table: "Basedata_WorkShop"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_WorkGroup_Code_Company", - table: "Basedata_WorkGroup"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Warehouse_Code_Company", - table: "Basedata_Warehouse"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Uom_Code_Company", - table: "Basedata_Uom"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_TransactionType_TransType_TransSubType_Company", - table: "Basedata_TransactionType"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Team_Code_Company", - table: "Basedata_Team"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_SupplierTime_SupplierCode_Company_TimeSlot_Week", - table: "Basedata_SupplierTime"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_SupplierItem_SupplierCode_ItemCode_Company", - table: "Basedata_SupplierItem"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Supplier_Code_Company", - table: "Basedata_Supplier"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_StrategyRule_StrategyId_RuleId_Company", - table: "Basedata_StrategyRule"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Strategy_Code_Company", - table: "Basedata_Strategy"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_StdCostPriceSheet_Code_Company_SupplierId", - table: "Basedata_StdCostPriceSheet"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Shift_Code_Company", - table: "Basedata_Shift"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_SalePriceSheet_Code_Company_CustomerId", - table: "Basedata_SalePriceSheet"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Rule_Code_Company", - table: "Basedata_Rule"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Route_Code_Company", - table: "Basedata_Route"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_PurchasePriceSheet_Code_Company", - table: "Basedata_PurchasePriceSheet"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Project_Code_Company", - table: "Basedata_Project"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ProductionLine_Code_Company", - table: "Basedata_ProductionLine"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ProdLineItem_ProdLineCode_ItemCode_Company", - table: "Basedata_ProdLineItem"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Param_Code_Company", - table: "Basedata_Param"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Machine_Code_Company", - table: "Basedata_Machine"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_LocationGroup_Code_Company", - table: "Basedata_LocationGroup"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Location_Code_Company", - table: "Basedata_Location"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemStoreRelation_ItemCode_Company_StoreRelationType_StoreValue", - table: "Basedata_ItemStoreRelation"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemSafetyStock_ItemCode_Company_WarehouseCode_StoreRelationType_StoreValue", - table: "Basedata_ItemSafetyStock"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemPack_Company_ItemCode_PackCode", - table: "Basedata_ItemPack"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemGuideBook_ItemCode_Company", - table: "Basedata_ItemGuideBook"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemCategory_Company_CategoryCode_ItemCode", - table: "Basedata_ItemCategory"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemBasic_Code_Company", - table: "Basedata_ItemBasic"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_InventoryRoute_Code_Company", - table: "Basedata_InventoryRoute"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_InterfaceCalendar_Code_Company", - table: "Basedata_InterfaceCalendar"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ErpLocation_Code_Company", - table: "Basedata_ErpLocation"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_DocumentSetting_Company_Code", - table: "Basedata_DocumentSetting"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Dock_Code_Company", - table: "Basedata_Dock"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Dict_Code_Company", - table: "Basedata_Dict"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_CustomerItem_Company_CustomerCode_ItemCode", - table: "Basedata_CustomerItem"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_CustomerBom_Company_CustomerId_ParentItemId_ChildItemId", - table: "Basedata_CustomerBom"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_CustomerAddress_Company_Code_CustomerCode", - table: "Basedata_CustomerAddress"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Customer_Code_Company", - table: "Basedata_Customer"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_CurrencyExchange_Company_CurrencyId_BasicCurrencyId", - table: "Basedata_CurrencyExchange"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Currency_Code_Company", - table: "Basedata_Currency"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Configuration_Company", - table: "Basedata_Configuration"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Category_Code_Company", - table: "Basedata_Category"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Calendar_Company", - table: "Basedata_Calendar"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Bom_Product_Company_Component", - table: "Basedata_Bom"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_AreaItem_Company_AreaId_ItemId", - table: "Basedata_AreaItem"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Area_Code_Company", - table: "Basedata_Area"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_AQL_SupplierCode_ItemCode_FloorQty_Company", - table: "Basedata_AQL"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_WorkStation"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_WorkShop"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_WorkGroup"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Warehouse"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Uom"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_TransactionType"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Team"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_SupplierTime"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_SupplierItem"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Supplier"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_StrategyRule"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Strategy"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_StdCostPriceSheet"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Shift"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_SalePriceSheet"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Rule"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Route"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_PurchasePriceSheet"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Project"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_ProductionLine"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_ProdLineItem"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Param"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Machine"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_LocationGroup"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Location"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_ItemStoreRelation"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_ItemSafetyStock"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_ItemQuality"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_ItemPack"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_ItemGuideBook"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_ItemCategory"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_ItemBasic"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_InventoryRoute"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_InterfaceCalendar"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_ErpLocation"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_DocumentSetting"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Dock"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Dict"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_CustomerItem"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_CustomerBom"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_CustomerAddress"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Customer"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_CurrencyExchange"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Currency"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Configuration"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Category"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Calendar"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Bom"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_AreaItem"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_Area"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Basedata_AQL"); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Basedata_ItemBasic", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_WorkStation_Code", - table: "Basedata_WorkStation", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_WorkShop_Code", - table: "Basedata_WorkShop", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_WorkGroup_Code", - table: "Basedata_WorkGroup", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Warehouse_Code", - table: "Basedata_Warehouse", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Uom_Code", - table: "Basedata_Uom", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_TransactionType_TransType_TransSubType", - table: "Basedata_TransactionType", - columns: new[] { "TransType", "TransSubType" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Team_Code", - table: "Basedata_Team", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SupplierTime_SupplierCode_TimeSlot_Week", - table: "Basedata_SupplierTime", - columns: new[] { "SupplierCode", "TimeSlot", "Week" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SupplierItem_SupplierCode_ItemCode", - table: "Basedata_SupplierItem", - columns: new[] { "SupplierCode", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Supplier_Code", - table: "Basedata_Supplier", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_StrategyRule_StrategyId_RuleId", - table: "Basedata_StrategyRule", - columns: new[] { "StrategyId", "RuleId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Strategy_Code", - table: "Basedata_Strategy", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_StdCostPriceSheet_Code_SupplierId", - table: "Basedata_StdCostPriceSheet", - columns: new[] { "Code", "SupplierId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Shift_Code", - table: "Basedata_Shift", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SalePriceSheet_Code_CustomerId", - table: "Basedata_SalePriceSheet", - columns: new[] { "Code", "CustomerId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Rule_Code", - table: "Basedata_Rule", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Route_Code", - table: "Basedata_Route", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_PurchasePriceSheet_Code", - table: "Basedata_PurchasePriceSheet", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Project_Code", - table: "Basedata_Project", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ProductionLine_Code", - table: "Basedata_ProductionLine", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ProdLineItem_ProdLineCode_ItemCode", - table: "Basedata_ProdLineItem", - columns: new[] { "ProdLineCode", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Param_Code", - table: "Basedata_Param", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Machine_Code", - table: "Basedata_Machine", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_LocationGroup_Code", - table: "Basedata_LocationGroup", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Location_Code", - table: "Basedata_Location", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemStoreRelation_ItemCode_StoreRelationType_StoreValue", - table: "Basedata_ItemStoreRelation", - columns: new[] { "ItemCode", "StoreRelationType", "StoreValue" }, - unique: true, - filter: "[StoreValue] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemSafetyStock_ItemCode_WarehouseCode_StoreRelationType_StoreValue", - table: "Basedata_ItemSafetyStock", - columns: new[] { "ItemCode", "WarehouseCode", "StoreRelationType", "StoreValue" }, - unique: true, - filter: "[StoreValue] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemPack_ItemCode_PackCode", - table: "Basedata_ItemPack", - columns: new[] { "ItemCode", "PackCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemGuideBook_ItemCode", - table: "Basedata_ItemGuideBook", - column: "ItemCode", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemCategory_CategoryCode_ItemCode", - table: "Basedata_ItemCategory", - columns: new[] { "CategoryCode", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemBasic_Code", - table: "Basedata_ItemBasic", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_InventoryRoute_Code", - table: "Basedata_InventoryRoute", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_InterfaceCalendar_Code", - table: "Basedata_InterfaceCalendar", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ErpLocation_Code", - table: "Basedata_ErpLocation", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_DocumentSetting_Code", - table: "Basedata_DocumentSetting", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Dock_Code", - table: "Basedata_Dock", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Dict_Code", - table: "Basedata_Dict", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CustomerItem_CustomerCode_ItemCode", - table: "Basedata_CustomerItem", - columns: new[] { "CustomerCode", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CustomerBom_CustomerId_ParentItemId_ChildItemId", - table: "Basedata_CustomerBom", - columns: new[] { "CustomerId", "ParentItemId", "ChildItemId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CustomerAddress_Code_CustomerCode", - table: "Basedata_CustomerAddress", - columns: new[] { "Code", "CustomerCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Customer_Code", - table: "Basedata_Customer", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CurrencyExchange_CurrencyId_BasicCurrencyId", - table: "Basedata_CurrencyExchange", - columns: new[] { "CurrencyId", "BasicCurrencyId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Currency_Code", - table: "Basedata_Currency", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Configuration_Key", - table: "Basedata_Configuration", - column: "Key", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Category_Code", - table: "Basedata_Category", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Calendar_Module", - table: "Basedata_Calendar", - column: "Module", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Bom_Product_Component", - table: "Basedata_Bom", - columns: new[] { "Product", "Component" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_AreaItem_AreaId_ItemId", - table: "Basedata_AreaItem", - columns: new[] { "AreaId", "ItemId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Area_Code", - table: "Basedata_Area", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_AQL_SupplierCode_ItemCode_FloorQty", - table: "Basedata_AQL", - columns: new[] { "SupplierCode", "ItemCode", "FloorQty" }, - unique: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Basedata_WorkStation_Code", - table: "Basedata_WorkStation"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_WorkShop_Code", - table: "Basedata_WorkShop"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_WorkGroup_Code", - table: "Basedata_WorkGroup"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Warehouse_Code", - table: "Basedata_Warehouse"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Uom_Code", - table: "Basedata_Uom"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_TransactionType_TransType_TransSubType", - table: "Basedata_TransactionType"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Team_Code", - table: "Basedata_Team"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_SupplierTime_SupplierCode_TimeSlot_Week", - table: "Basedata_SupplierTime"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_SupplierItem_SupplierCode_ItemCode", - table: "Basedata_SupplierItem"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Supplier_Code", - table: "Basedata_Supplier"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_StrategyRule_StrategyId_RuleId", - table: "Basedata_StrategyRule"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Strategy_Code", - table: "Basedata_Strategy"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_StdCostPriceSheet_Code_SupplierId", - table: "Basedata_StdCostPriceSheet"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Shift_Code", - table: "Basedata_Shift"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_SalePriceSheet_Code_CustomerId", - table: "Basedata_SalePriceSheet"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Rule_Code", - table: "Basedata_Rule"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Route_Code", - table: "Basedata_Route"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_PurchasePriceSheet_Code", - table: "Basedata_PurchasePriceSheet"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Project_Code", - table: "Basedata_Project"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ProductionLine_Code", - table: "Basedata_ProductionLine"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ProdLineItem_ProdLineCode_ItemCode", - table: "Basedata_ProdLineItem"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Param_Code", - table: "Basedata_Param"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Machine_Code", - table: "Basedata_Machine"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_LocationGroup_Code", - table: "Basedata_LocationGroup"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Location_Code", - table: "Basedata_Location"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemStoreRelation_ItemCode_StoreRelationType_StoreValue", - table: "Basedata_ItemStoreRelation"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemSafetyStock_ItemCode_WarehouseCode_StoreRelationType_StoreValue", - table: "Basedata_ItemSafetyStock"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemPack_ItemCode_PackCode", - table: "Basedata_ItemPack"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemGuideBook_ItemCode", - table: "Basedata_ItemGuideBook"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemCategory_CategoryCode_ItemCode", - table: "Basedata_ItemCategory"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ItemBasic_Code", - table: "Basedata_ItemBasic"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_InventoryRoute_Code", - table: "Basedata_InventoryRoute"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_InterfaceCalendar_Code", - table: "Basedata_InterfaceCalendar"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_ErpLocation_Code", - table: "Basedata_ErpLocation"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_DocumentSetting_Code", - table: "Basedata_DocumentSetting"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Dock_Code", - table: "Basedata_Dock"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Dict_Code", - table: "Basedata_Dict"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_CustomerItem_CustomerCode_ItemCode", - table: "Basedata_CustomerItem"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_CustomerBom_CustomerId_ParentItemId_ChildItemId", - table: "Basedata_CustomerBom"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_CustomerAddress_Code_CustomerCode", - table: "Basedata_CustomerAddress"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Customer_Code", - table: "Basedata_Customer"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_CurrencyExchange_CurrencyId_BasicCurrencyId", - table: "Basedata_CurrencyExchange"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Currency_Code", - table: "Basedata_Currency"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Configuration_Key", - table: "Basedata_Configuration"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Category_Code", - table: "Basedata_Category"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Calendar_Module", - table: "Basedata_Calendar"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Bom_Product_Component", - table: "Basedata_Bom"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_AreaItem_AreaId_ItemId", - table: "Basedata_AreaItem"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_Area_Code", - table: "Basedata_Area"); - - migrationBuilder.DropIndex( - name: "IX_Basedata_AQL_SupplierCode_ItemCode_FloorQty", - table: "Basedata_AQL"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Basedata_ItemBasic"); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_WorkStation", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_WorkShop", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_WorkGroup", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Warehouse", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Uom", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_TransactionType", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Team", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_SupplierTime", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_SupplierItem", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Supplier", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_StrategyRule", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Strategy", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_StdCostPriceSheet", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Shift", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_SalePriceSheet", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Rule", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Route", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_PurchasePriceSheet", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Project", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_ProductionLine", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_ProdLineItem", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Param", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Machine", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_LocationGroup", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Location", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_ItemStoreRelation", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_ItemSafetyStock", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_ItemQuality", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_ItemPack", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_ItemGuideBook", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_ItemCategory", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_ItemBasic", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_InventoryRoute", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_InterfaceCalendar", - type: "nvarchar(450)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_ErpLocation", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_DocumentSetting", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Dock", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Dict", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_CustomerItem", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_CustomerBom", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_CustomerAddress", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Customer", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_CurrencyExchange", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Currency", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Configuration", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Category", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Calendar", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Bom", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_AreaItem", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_Area", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Company", - table: "Basedata_AQL", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.CreateTable( - name: "Basedata_Company", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - FullName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - Logo = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - PrimaryProduct = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Company", x => x.Id); - }); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_WorkStation_Code_Company", - table: "Basedata_WorkStation", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_WorkShop_Code_Company", - table: "Basedata_WorkShop", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_WorkGroup_Code_Company", - table: "Basedata_WorkGroup", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Warehouse_Code_Company", - table: "Basedata_Warehouse", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Uom_Code_Company", - table: "Basedata_Uom", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_TransactionType_TransType_TransSubType_Company", - table: "Basedata_TransactionType", - columns: new[] { "TransType", "TransSubType", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Team_Code_Company", - table: "Basedata_Team", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SupplierTime_SupplierCode_Company_TimeSlot_Week", - table: "Basedata_SupplierTime", - columns: new[] { "SupplierCode", "Company", "TimeSlot", "Week" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SupplierItem_SupplierCode_ItemCode_Company", - table: "Basedata_SupplierItem", - columns: new[] { "SupplierCode", "ItemCode", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Supplier_Code_Company", - table: "Basedata_Supplier", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_StrategyRule_StrategyId_RuleId_Company", - table: "Basedata_StrategyRule", - columns: new[] { "StrategyId", "RuleId", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Strategy_Code_Company", - table: "Basedata_Strategy", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_StdCostPriceSheet_Code_Company_SupplierId", - table: "Basedata_StdCostPriceSheet", - columns: new[] { "Code", "Company", "SupplierId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Shift_Code_Company", - table: "Basedata_Shift", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SalePriceSheet_Code_Company_CustomerId", - table: "Basedata_SalePriceSheet", - columns: new[] { "Code", "Company", "CustomerId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Rule_Code_Company", - table: "Basedata_Rule", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Route_Code_Company", - table: "Basedata_Route", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_PurchasePriceSheet_Code_Company", - table: "Basedata_PurchasePriceSheet", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Project_Code_Company", - table: "Basedata_Project", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ProductionLine_Code_Company", - table: "Basedata_ProductionLine", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ProdLineItem_ProdLineCode_ItemCode_Company", - table: "Basedata_ProdLineItem", - columns: new[] { "ProdLineCode", "ItemCode", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Param_Code_Company", - table: "Basedata_Param", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Machine_Code_Company", - table: "Basedata_Machine", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_LocationGroup_Code_Company", - table: "Basedata_LocationGroup", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Location_Code_Company", - table: "Basedata_Location", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemStoreRelation_ItemCode_Company_StoreRelationType_StoreValue", - table: "Basedata_ItemStoreRelation", - columns: new[] { "ItemCode", "Company", "StoreRelationType", "StoreValue" }, - unique: true, - filter: "[StoreValue] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemSafetyStock_ItemCode_Company_WarehouseCode_StoreRelationType_StoreValue", - table: "Basedata_ItemSafetyStock", - columns: new[] { "ItemCode", "Company", "WarehouseCode", "StoreRelationType", "StoreValue" }, - unique: true, - filter: "[StoreValue] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemPack_Company_ItemCode_PackCode", - table: "Basedata_ItemPack", - columns: new[] { "Company", "ItemCode", "PackCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemGuideBook_ItemCode_Company", - table: "Basedata_ItemGuideBook", - columns: new[] { "ItemCode", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemCategory_Company_CategoryCode_ItemCode", - table: "Basedata_ItemCategory", - columns: new[] { "Company", "CategoryCode", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ItemBasic_Code_Company", - table: "Basedata_ItemBasic", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_InventoryRoute_Code_Company", - table: "Basedata_InventoryRoute", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_InterfaceCalendar_Code_Company", - table: "Basedata_InterfaceCalendar", - columns: new[] { "Code", "Company" }, - unique: true, - filter: "[Company] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ErpLocation_Code_Company", - table: "Basedata_ErpLocation", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_DocumentSetting_Company_Code", - table: "Basedata_DocumentSetting", - columns: new[] { "Company", "Code" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Dock_Code_Company", - table: "Basedata_Dock", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Dict_Code_Company", - table: "Basedata_Dict", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CustomerItem_Company_CustomerCode_ItemCode", - table: "Basedata_CustomerItem", - columns: new[] { "Company", "CustomerCode", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CustomerBom_Company_CustomerId_ParentItemId_ChildItemId", - table: "Basedata_CustomerBom", - columns: new[] { "Company", "CustomerId", "ParentItemId", "ChildItemId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CustomerAddress_Company_Code_CustomerCode", - table: "Basedata_CustomerAddress", - columns: new[] { "Company", "Code", "CustomerCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Customer_Code_Company", - table: "Basedata_Customer", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CurrencyExchange_Company_CurrencyId_BasicCurrencyId", - table: "Basedata_CurrencyExchange", - columns: new[] { "Company", "CurrencyId", "BasicCurrencyId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Currency_Code_Company", - table: "Basedata_Currency", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Configuration_Company", - table: "Basedata_Configuration", - column: "Company", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Category_Code_Company", - table: "Basedata_Category", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Calendar_Company", - table: "Basedata_Calendar", - column: "Company", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Bom_Product_Company_Component", - table: "Basedata_Bom", - columns: new[] { "Product", "Company", "Component" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_AreaItem_Company_AreaId_ItemId", - table: "Basedata_AreaItem", - columns: new[] { "Company", "AreaId", "ItemId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Area_Code_Company", - table: "Basedata_Area", - columns: new[] { "Code", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_AQL_SupplierCode_ItemCode_FloorQty_Company", - table: "Basedata_AQL", - columns: new[] { "SupplierCode", "ItemCode", "FloorQty", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Company_Code_Company", - table: "Basedata_Company", - columns: new[] { "Code", "Company" }, - unique: true); - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109015022_FlatUomQtyPackingInfoAndTimeRange.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109015022_FlatUomQtyPackingInfoAndTimeRange.Designer.cs deleted file mode 100644 index 294779884..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109015022_FlatUomQtyPackingInfoAndTimeRange.Designer.cs +++ /dev/null @@ -1,4078 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - [Migration("20230109015022_FlatUomQtyPackingInfoAndTimeRange")] - partial class FlatUomQtyPackingInfoAndTimeRange - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty") - .IsUnique(); - - b.ToTable("Basedata_AQL", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .HasColumnType("int"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Area", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AreaItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Allowed") - .HasColumnType("bit"); - - b.Property("AreaId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UomId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("AreaId", "ItemId") - .IsUnique(); - - b.ToTable("Basedata_AreaItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ComponentQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ComponentUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .HasColumnType("int"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .HasColumnType("int"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Module") - .IsUnique() - .HasFilter("[Module] IS NOT NULL"); - - b.ToTable("Basedata_Calendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Category", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Configuration", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Key") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Key") - .IsUnique(); - - b.ToTable("Basedata_Configuration", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Currency", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Customer", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerBom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ChildItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FailureTime") - .HasColumnType("datetime2"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ParentItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CustomerId", "ParentItemId", "ChildItemId") - .IsUnique(); - - b.ToTable("Basedata_CustomerBom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dict", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InterfaceCalendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InventoryRoute", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InventoryRoute", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .HasColumnType("int"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLine") - .HasColumnType("nvarchar(max)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .HasColumnType("int"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CategoryCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "WarehouseCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemSafetyStock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Location", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Machine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Param", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Param", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProdLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ProdLineItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Project", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Route", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Route", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Rule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Rule", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Shift", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Strategy", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Strategy", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StrategyRule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RuleId") - .HasColumnType("uniqueidentifier"); - - b.Property("Seq") - .HasColumnType("int"); - - b.Property("StrategyId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("StrategyId", "RuleId") - .IsUnique(); - - b.ToTable("Basedata_StrategyRule", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Supplier", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTime", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTime", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Team", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .HasColumnType("int"); - - b.Property("TransType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType") - .IsUnique(); - - b.ToTable("Basedata_TransactionType", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Uom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Warehouse", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkShop", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkStation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemGuideBookId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemGuideBookId"); - - b1.ToTable("Basedata_ItemGuideBook", "dbo"); - - b1.WithOwner() - .HasForeignKey("ItemGuideBookId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.LocationSwitch", "LocSwitch", b1 => - { - b1.Property("LocationId") - .HasColumnType("uniqueidentifier"); - - b1.Property("EnableBreakStore") - .HasColumnType("bit"); - - b1.Property("EnableKeepZero") - .HasColumnType("bit"); - - b1.Property("EnableMixItem") - .HasColumnType("bit"); - - b1.Property("EnableMixLot") - .HasColumnType("bit"); - - b1.Property("EnableMixStatus") - .HasColumnType("bit"); - - b1.Property("EnableNegative") - .HasColumnType("bit"); - - b1.Property("EnableOpportunityCount") - .HasColumnType("bit"); - - b1.Property("EnableOverPick") - .HasColumnType("bit"); - - b1.Property("EnablePick") - .HasColumnType("bit"); - - b1.Property("EnableReceive") - .HasColumnType("bit"); - - b1.Property("EnableReturnFromCustomer") - .HasColumnType("bit"); - - b1.Property("EnableReturnToSupplier") - .HasColumnType("bit"); - - b1.Property("EnableShip") - .HasColumnType("bit"); - - b1.Property("EnableSplitBox") - .HasColumnType("bit"); - - b1.Property("EnableSplitPallet") - .HasColumnType("bit"); - - b1.Property("EnableWholeStore") - .HasColumnType("bit"); - - b1.HasKey("LocationId"); - - b1.ToTable("Basedata_Location", "dbo"); - - b1.WithOwner() - .HasForeignKey("LocationId"); - }); - - b.Navigation("LocSwitch"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.LocationSwitch", "LocSwitch", b1 => - { - b1.Property("LocationGroupId") - .HasColumnType("uniqueidentifier"); - - b1.Property("EnableBreakStore") - .HasColumnType("bit"); - - b1.Property("EnableKeepZero") - .HasColumnType("bit"); - - b1.Property("EnableMixItem") - .HasColumnType("bit"); - - b1.Property("EnableMixLot") - .HasColumnType("bit"); - - b1.Property("EnableMixStatus") - .HasColumnType("bit"); - - b1.Property("EnableNegative") - .HasColumnType("bit"); - - b1.Property("EnableOpportunityCount") - .HasColumnType("bit"); - - b1.Property("EnableOverPick") - .HasColumnType("bit"); - - b1.Property("EnablePick") - .HasColumnType("bit"); - - b1.Property("EnableReceive") - .HasColumnType("bit"); - - b1.Property("EnableReturnFromCustomer") - .HasColumnType("bit"); - - b1.Property("EnableReturnToSupplier") - .HasColumnType("bit"); - - b1.Property("EnableShip") - .HasColumnType("bit"); - - b1.Property("EnableSplitBox") - .HasColumnType("bit"); - - b1.Property("EnableSplitPallet") - .HasColumnType("bit"); - - b1.Property("EnableWholeStore") - .HasColumnType("bit"); - - b1.HasKey("LocationGroupId"); - - b1.ToTable("Basedata_LocationGroup", "dbo"); - - b1.WithOwner() - .HasForeignKey("LocationGroupId"); - }); - - b.Navigation("LocSwitch"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109015022_FlatUomQtyPackingInfoAndTimeRange.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109015022_FlatUomQtyPackingInfoAndTimeRange.cs deleted file mode 100644 index 228cff2b7..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109015022_FlatUomQtyPackingInfoAndTimeRange.cs +++ /dev/null @@ -1,909 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations; - -public partial class FlatUomQtyPackingInfoAndTimeRange : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Basedata_Calendar_Module", - table: "Basedata_Calendar"); - - migrationBuilder.DropColumn( - name: "SupplierPackQty_Qty", - table: "Basedata_SupplierItem"); - - migrationBuilder.DropColumn( - name: "ConversionRate", - table: "Basedata_ItemPack"); - - migrationBuilder.DropColumn( - name: "IsStdPack", - table: "Basedata_ItemPack"); - - migrationBuilder.DropColumn( - name: "PackQty_Uom", - table: "Basedata_ItemPack"); - - migrationBuilder.DropColumn( - name: "CustomerPackQty_Qty", - table: "Basedata_CustomerItem"); - - migrationBuilder.DropColumn( - name: "PerQty_Qty", - table: "Basedata_Bom"); - - migrationBuilder.EnsureSchema( - name: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_WorkStation", - newName: "Basedata_WorkStation", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_WorkShop", - newName: "Basedata_WorkShop", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_WorkGroup", - newName: "Basedata_WorkGroup", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Warehouse", - newName: "Basedata_Warehouse", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Uom", - newName: "Basedata_Uom", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_TransactionType", - newName: "Basedata_TransactionType", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Team", - newName: "Basedata_Team", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_SupplierTime", - newName: "Basedata_SupplierTime", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_SupplierItem", - newName: "Basedata_SupplierItem", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Supplier", - newName: "Basedata_Supplier", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_StrategyRule", - newName: "Basedata_StrategyRule", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Strategy", - newName: "Basedata_Strategy", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_StdCostPriceSheet", - newName: "Basedata_StdCostPriceSheet", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Shift", - newName: "Basedata_Shift", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_SalePriceSheet", - newName: "Basedata_SalePriceSheet", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Rule", - newName: "Basedata_Rule", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Route", - newName: "Basedata_Route", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_PurchasePriceSheet", - newName: "Basedata_PurchasePriceSheet", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Project", - newName: "Basedata_Project", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_ProductionLine", - newName: "Basedata_ProductionLine", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_ProdLineItem", - newName: "Basedata_ProdLineItem", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Param", - newName: "Basedata_Param", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Machine", - newName: "Basedata_Machine", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_LocationGroup", - newName: "Basedata_LocationGroup", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Location", - newName: "Basedata_Location", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemStoreRelation", - newName: "Basedata_ItemStoreRelation", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemSafetyStock", - newName: "Basedata_ItemSafetyStock", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemQuality", - newName: "Basedata_ItemQuality", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemPack", - newName: "Basedata_ItemPack", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemGuideBook", - newName: "Basedata_ItemGuideBook", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemCategory", - newName: "Basedata_ItemCategory", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemBasic", - newName: "Basedata_ItemBasic", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_InventoryRoute", - newName: "Basedata_InventoryRoute", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_InterfaceCalendar", - newName: "Basedata_InterfaceCalendar", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_ErpLocation", - newName: "Basedata_ErpLocation", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_DocumentSetting", - newName: "Basedata_DocumentSetting", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Dock", - newName: "Basedata_Dock", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_DictItem", - newName: "Basedata_DictItem", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Dict", - newName: "Basedata_Dict", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_CustomerItem", - newName: "Basedata_CustomerItem", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_CustomerBom", - newName: "Basedata_CustomerBom", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_CustomerAddress", - newName: "Basedata_CustomerAddress", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Customer", - newName: "Basedata_Customer", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_CurrencyExchange", - newName: "Basedata_CurrencyExchange", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Currency", - newName: "Basedata_Currency", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Configuration", - newName: "Basedata_Configuration", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Category", - newName: "Basedata_Category", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Calendar", - newName: "Basedata_Calendar", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Bom", - newName: "Basedata_Bom", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_AreaItem", - newName: "Basedata_AreaItem", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_Area", - newName: "Basedata_Area", - newSchema: "dbo"); - - migrationBuilder.RenameTable( - name: "Basedata_AQL", - newName: "Basedata_AQL", - newSchema: "dbo"); - - migrationBuilder.RenameColumn( - name: "SupplierPackQty_Uom", - schema: "dbo", - table: "Basedata_SupplierItem", - newName: "SupplierPackUom"); - - migrationBuilder.RenameColumn( - name: "TimeRange_EndTime", - schema: "dbo", - table: "Basedata_Shift", - newName: "EndTime"); - - migrationBuilder.RenameColumn( - name: "TimeRange_BeginTime", - schema: "dbo", - table: "Basedata_Shift", - newName: "BeginTime"); - - migrationBuilder.RenameColumn( - name: "TimeRange_EndTime", - schema: "dbo", - table: "Basedata_Project", - newName: "EndTime"); - - migrationBuilder.RenameColumn( - name: "TimeRange_BeginTime", - schema: "dbo", - table: "Basedata_Project", - newName: "BeginTime"); - - migrationBuilder.RenameColumn( - name: "PackQty_Qty", - schema: "dbo", - table: "Basedata_ItemPack", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "StdPackCode", - schema: "dbo", - table: "Basedata_ItemPack", - newName: "BasicUom"); - - migrationBuilder.RenameColumn( - name: "TimeRange_EndTime", - schema: "dbo", - table: "Basedata_CustomerItem", - newName: "EndTime"); - - migrationBuilder.RenameColumn( - name: "TimeRange_BeginTime", - schema: "dbo", - table: "Basedata_CustomerItem", - newName: "BeginTime"); - - migrationBuilder.RenameColumn( - name: "CustomerPackQty_Uom", - schema: "dbo", - table: "Basedata_CustomerItem", - newName: "CustomerPackUom"); - - migrationBuilder.RenameColumn( - name: "TimeRange_EndTime", - schema: "dbo", - table: "Basedata_Calendar", - newName: "EndTime"); - - migrationBuilder.RenameColumn( - name: "TimeRange_BeginTime", - schema: "dbo", - table: "Basedata_Calendar", - newName: "BeginTime"); - - migrationBuilder.RenameColumn( - name: "TimeRange_EndTime", - schema: "dbo", - table: "Basedata_Bom", - newName: "EndTime"); - - migrationBuilder.RenameColumn( - name: "TimeRange_BeginTime", - schema: "dbo", - table: "Basedata_Bom", - newName: "BeginTime"); - - migrationBuilder.RenameColumn( - name: "PerQty_Uom", - schema: "dbo", - table: "Basedata_Bom", - newName: "ComponentUom"); - - migrationBuilder.AddColumn( - name: "SupplierPackQty", - schema: "dbo", - table: "Basedata_SupplierItem", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - schema: "dbo", - table: "Basedata_ItemPack", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "CustomerPackQty", - schema: "dbo", - table: "Basedata_CustomerItem", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Module", - schema: "dbo", - table: "Basedata_Calendar", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "EndTime", - schema: "dbo", - table: "Basedata_Calendar", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "BeginTime", - schema: "dbo", - table: "Basedata_Calendar", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "ComponentQty", - schema: "dbo", - table: "Basedata_Bom", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Calendar_Module", - schema: "dbo", - table: "Basedata_Calendar", - column: "Module", - unique: true, - filter: "[Module] IS NOT NULL"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Basedata_Calendar_Module", - schema: "dbo", - table: "Basedata_Calendar"); - - migrationBuilder.DropColumn( - name: "SupplierPackQty", - schema: "dbo", - table: "Basedata_SupplierItem"); - - migrationBuilder.DropColumn( - name: "CustomerPackQty", - schema: "dbo", - table: "Basedata_CustomerItem"); - - migrationBuilder.DropColumn( - name: "ComponentQty", - schema: "dbo", - table: "Basedata_Bom"); - - migrationBuilder.RenameTable( - name: "Basedata_WorkStation", - schema: "dbo", - newName: "Basedata_WorkStation"); - - migrationBuilder.RenameTable( - name: "Basedata_WorkShop", - schema: "dbo", - newName: "Basedata_WorkShop"); - - migrationBuilder.RenameTable( - name: "Basedata_WorkGroup", - schema: "dbo", - newName: "Basedata_WorkGroup"); - - migrationBuilder.RenameTable( - name: "Basedata_Warehouse", - schema: "dbo", - newName: "Basedata_Warehouse"); - - migrationBuilder.RenameTable( - name: "Basedata_Uom", - schema: "dbo", - newName: "Basedata_Uom"); - - migrationBuilder.RenameTable( - name: "Basedata_TransactionType", - schema: "dbo", - newName: "Basedata_TransactionType"); - - migrationBuilder.RenameTable( - name: "Basedata_Team", - schema: "dbo", - newName: "Basedata_Team"); - - migrationBuilder.RenameTable( - name: "Basedata_SupplierTime", - schema: "dbo", - newName: "Basedata_SupplierTime"); - - migrationBuilder.RenameTable( - name: "Basedata_SupplierItem", - schema: "dbo", - newName: "Basedata_SupplierItem"); - - migrationBuilder.RenameTable( - name: "Basedata_Supplier", - schema: "dbo", - newName: "Basedata_Supplier"); - - migrationBuilder.RenameTable( - name: "Basedata_StrategyRule", - schema: "dbo", - newName: "Basedata_StrategyRule"); - - migrationBuilder.RenameTable( - name: "Basedata_Strategy", - schema: "dbo", - newName: "Basedata_Strategy"); - - migrationBuilder.RenameTable( - name: "Basedata_StdCostPriceSheet", - schema: "dbo", - newName: "Basedata_StdCostPriceSheet"); - - migrationBuilder.RenameTable( - name: "Basedata_Shift", - schema: "dbo", - newName: "Basedata_Shift"); - - migrationBuilder.RenameTable( - name: "Basedata_SalePriceSheet", - schema: "dbo", - newName: "Basedata_SalePriceSheet"); - - migrationBuilder.RenameTable( - name: "Basedata_Rule", - schema: "dbo", - newName: "Basedata_Rule"); - - migrationBuilder.RenameTable( - name: "Basedata_Route", - schema: "dbo", - newName: "Basedata_Route"); - - migrationBuilder.RenameTable( - name: "Basedata_PurchasePriceSheet", - schema: "dbo", - newName: "Basedata_PurchasePriceSheet"); - - migrationBuilder.RenameTable( - name: "Basedata_Project", - schema: "dbo", - newName: "Basedata_Project"); - - migrationBuilder.RenameTable( - name: "Basedata_ProductionLine", - schema: "dbo", - newName: "Basedata_ProductionLine"); - - migrationBuilder.RenameTable( - name: "Basedata_ProdLineItem", - schema: "dbo", - newName: "Basedata_ProdLineItem"); - - migrationBuilder.RenameTable( - name: "Basedata_Param", - schema: "dbo", - newName: "Basedata_Param"); - - migrationBuilder.RenameTable( - name: "Basedata_Machine", - schema: "dbo", - newName: "Basedata_Machine"); - - migrationBuilder.RenameTable( - name: "Basedata_LocationGroup", - schema: "dbo", - newName: "Basedata_LocationGroup"); - - migrationBuilder.RenameTable( - name: "Basedata_Location", - schema: "dbo", - newName: "Basedata_Location"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemStoreRelation", - schema: "dbo", - newName: "Basedata_ItemStoreRelation"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemSafetyStock", - schema: "dbo", - newName: "Basedata_ItemSafetyStock"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemQuality", - schema: "dbo", - newName: "Basedata_ItemQuality"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemPack", - schema: "dbo", - newName: "Basedata_ItemPack"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemGuideBook", - schema: "dbo", - newName: "Basedata_ItemGuideBook"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemCategory", - schema: "dbo", - newName: "Basedata_ItemCategory"); - - migrationBuilder.RenameTable( - name: "Basedata_ItemBasic", - schema: "dbo", - newName: "Basedata_ItemBasic"); - - migrationBuilder.RenameTable( - name: "Basedata_InventoryRoute", - schema: "dbo", - newName: "Basedata_InventoryRoute"); - - migrationBuilder.RenameTable( - name: "Basedata_InterfaceCalendar", - schema: "dbo", - newName: "Basedata_InterfaceCalendar"); - - migrationBuilder.RenameTable( - name: "Basedata_ErpLocation", - schema: "dbo", - newName: "Basedata_ErpLocation"); - - migrationBuilder.RenameTable( - name: "Basedata_DocumentSetting", - schema: "dbo", - newName: "Basedata_DocumentSetting"); - - migrationBuilder.RenameTable( - name: "Basedata_Dock", - schema: "dbo", - newName: "Basedata_Dock"); - - migrationBuilder.RenameTable( - name: "Basedata_DictItem", - schema: "dbo", - newName: "Basedata_DictItem"); - - migrationBuilder.RenameTable( - name: "Basedata_Dict", - schema: "dbo", - newName: "Basedata_Dict"); - - migrationBuilder.RenameTable( - name: "Basedata_CustomerItem", - schema: "dbo", - newName: "Basedata_CustomerItem"); - - migrationBuilder.RenameTable( - name: "Basedata_CustomerBom", - schema: "dbo", - newName: "Basedata_CustomerBom"); - - migrationBuilder.RenameTable( - name: "Basedata_CustomerAddress", - schema: "dbo", - newName: "Basedata_CustomerAddress"); - - migrationBuilder.RenameTable( - name: "Basedata_Customer", - schema: "dbo", - newName: "Basedata_Customer"); - - migrationBuilder.RenameTable( - name: "Basedata_CurrencyExchange", - schema: "dbo", - newName: "Basedata_CurrencyExchange"); - - migrationBuilder.RenameTable( - name: "Basedata_Currency", - schema: "dbo", - newName: "Basedata_Currency"); - - migrationBuilder.RenameTable( - name: "Basedata_Configuration", - schema: "dbo", - newName: "Basedata_Configuration"); - - migrationBuilder.RenameTable( - name: "Basedata_Category", - schema: "dbo", - newName: "Basedata_Category"); - - migrationBuilder.RenameTable( - name: "Basedata_Calendar", - schema: "dbo", - newName: "Basedata_Calendar"); - - migrationBuilder.RenameTable( - name: "Basedata_Bom", - schema: "dbo", - newName: "Basedata_Bom"); - - migrationBuilder.RenameTable( - name: "Basedata_AreaItem", - schema: "dbo", - newName: "Basedata_AreaItem"); - - migrationBuilder.RenameTable( - name: "Basedata_Area", - schema: "dbo", - newName: "Basedata_Area"); - - migrationBuilder.RenameTable( - name: "Basedata_AQL", - schema: "dbo", - newName: "Basedata_AQL"); - - migrationBuilder.RenameColumn( - name: "SupplierPackUom", - table: "Basedata_SupplierItem", - newName: "SupplierPackQty_Uom"); - - migrationBuilder.RenameColumn( - name: "EndTime", - table: "Basedata_Shift", - newName: "TimeRange_EndTime"); - - migrationBuilder.RenameColumn( - name: "BeginTime", - table: "Basedata_Shift", - newName: "TimeRange_BeginTime"); - - migrationBuilder.RenameColumn( - name: "EndTime", - table: "Basedata_Project", - newName: "TimeRange_EndTime"); - - migrationBuilder.RenameColumn( - name: "BeginTime", - table: "Basedata_Project", - newName: "TimeRange_BeginTime"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Basedata_ItemPack", - newName: "PackQty_Qty"); - - migrationBuilder.RenameColumn( - name: "BasicUom", - table: "Basedata_ItemPack", - newName: "StdPackCode"); - - migrationBuilder.RenameColumn( - name: "EndTime", - table: "Basedata_CustomerItem", - newName: "TimeRange_EndTime"); - - migrationBuilder.RenameColumn( - name: "BeginTime", - table: "Basedata_CustomerItem", - newName: "TimeRange_BeginTime"); - - migrationBuilder.RenameColumn( - name: "CustomerPackUom", - table: "Basedata_CustomerItem", - newName: "CustomerPackQty_Uom"); - - migrationBuilder.RenameColumn( - name: "EndTime", - table: "Basedata_Calendar", - newName: "TimeRange_EndTime"); - - migrationBuilder.RenameColumn( - name: "BeginTime", - table: "Basedata_Calendar", - newName: "TimeRange_BeginTime"); - - migrationBuilder.RenameColumn( - name: "EndTime", - table: "Basedata_Bom", - newName: "TimeRange_EndTime"); - - migrationBuilder.RenameColumn( - name: "BeginTime", - table: "Basedata_Bom", - newName: "TimeRange_BeginTime"); - - migrationBuilder.RenameColumn( - name: "ComponentUom", - table: "Basedata_Bom", - newName: "PerQty_Uom"); - - migrationBuilder.AddColumn( - name: "SupplierPackQty_Qty", - table: "Basedata_SupplierItem", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "PackQty_Qty", - table: "Basedata_ItemPack", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "ConversionRate", - table: "Basedata_ItemPack", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "IsStdPack", - table: "Basedata_ItemPack", - type: "bit", - maxLength: 64, - nullable: false, - defaultValue: false); - - migrationBuilder.AddColumn( - name: "PackQty_Uom", - table: "Basedata_ItemPack", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "CustomerPackQty_Qty", - table: "Basedata_CustomerItem", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "Module", - table: "Basedata_Calendar", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "TimeRange_EndTime", - table: "Basedata_Calendar", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "TimeRange_BeginTime", - table: "Basedata_Calendar", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "PerQty_Qty", - table: "Basedata_Bom", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Calendar_Module", - table: "Basedata_Calendar", - column: "Module", - unique: true); - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109071524_FlatLocationSwitch.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109071524_FlatLocationSwitch.Designer.cs deleted file mode 100644 index bddcff446..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109071524_FlatLocationSwitch.Designer.cs +++ /dev/null @@ -1,4106 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - [Migration("20230109071524_FlatLocationSwitch")] - partial class FlatLocationSwitch - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty") - .IsUnique(); - - b.ToTable("Basedata_AQL", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .HasColumnType("int"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Area", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AreaItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Allowed") - .HasColumnType("bit"); - - b.Property("AreaId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UomId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("AreaId", "ItemId") - .IsUnique(); - - b.ToTable("Basedata_AreaItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ComponentQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ComponentUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .HasColumnType("int"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .HasColumnType("int"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Module") - .IsUnique() - .HasFilter("[Module] IS NOT NULL"); - - b.ToTable("Basedata_Calendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Category", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Configuration", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Key") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Key") - .IsUnique(); - - b.ToTable("Basedata_Configuration", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Currency", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Customer", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerBom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ChildItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FailureTime") - .HasColumnType("datetime2"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ParentItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CustomerId", "ParentItemId", "ChildItemId") - .IsUnique(); - - b.ToTable("Basedata_CustomerBom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dict", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InterfaceCalendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InventoryRoute", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InventoryRoute", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .HasColumnType("int"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLine") - .HasColumnType("nvarchar(max)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .HasColumnType("int"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CategoryCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "WarehouseCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemSafetyStock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Location", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Machine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Param", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Param", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProdLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ProdLineItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Project", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Route", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Route", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Rule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Rule", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Shift", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Strategy", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Strategy", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StrategyRule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RuleId") - .HasColumnType("uniqueidentifier"); - - b.Property("Seq") - .HasColumnType("int"); - - b.Property("StrategyId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("StrategyId", "RuleId") - .IsUnique(); - - b.ToTable("Basedata_StrategyRule", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Supplier", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTime", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTime", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Team", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .HasColumnType("int"); - - b.Property("TransType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType") - .IsUnique(); - - b.ToTable("Basedata_TransactionType", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Uom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Warehouse", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkShop", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkStation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemGuideBookId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemGuideBookId"); - - b1.ToTable("Basedata_ItemGuideBook", "dbo"); - - b1.WithOwner() - .HasForeignKey("ItemGuideBookId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109071524_FlatLocationSwitch.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109071524_FlatLocationSwitch.cs deleted file mode 100644 index 0f45aff88..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230109071524_FlatLocationSwitch.cs +++ /dev/null @@ -1,1070 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations; - -public partial class FlatLocationSwitch : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableWholeStore", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableWholeStore"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableSplitPallet", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableSplitPallet"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableSplitBox", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableSplitBox"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableShip", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableShip"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableReturnToSupplier", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableReturnToSupplier"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableReturnFromCustomer", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableReturnFromCustomer"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableReceive", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableReceive"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnablePick", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnablePick"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableOverPick", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableOverPick"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableOpportunityCount", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableOpportunityCount"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableNegative", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableNegative"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableMixStatus", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableMixStatus"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableMixLot", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableMixLot"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableMixItem", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableMixItem"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableKeepZero", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableKeepZero"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableBreakStore", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "EnableBreakStore"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableWholeStore", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableWholeStore"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableSplitPallet", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableSplitPallet"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableSplitBox", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableSplitBox"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableShip", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableShip"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableReturnToSupplier", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableReturnToSupplier"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableReturnFromCustomer", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableReturnFromCustomer"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableReceive", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableReceive"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnablePick", - schema: "dbo", - table: "Basedata_Location", - newName: "EnablePick"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableOverPick", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableOverPick"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableOpportunityCount", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableOpportunityCount"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableNegative", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableNegative"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableMixStatus", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableMixStatus"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableMixLot", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableMixLot"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableMixItem", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableMixItem"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableKeepZero", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableKeepZero"); - - migrationBuilder.RenameColumn( - name: "LocSwitch_EnableBreakStore", - schema: "dbo", - table: "Basedata_Location", - newName: "EnableBreakStore"); - - migrationBuilder.AlterColumn( - name: "EnableWholeStore", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableSplitPallet", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableSplitBox", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableShip", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableReturnToSupplier", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableReturnFromCustomer", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableReceive", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnablePick", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableOverPick", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableOpportunityCount", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableNegative", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableMixStatus", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableMixLot", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableMixItem", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableKeepZero", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableBreakStore", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableWholeStore", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableSplitPallet", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableSplitBox", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableShip", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableReturnToSupplier", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableReturnFromCustomer", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableReceive", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnablePick", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableOverPick", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableOpportunityCount", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableNegative", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableMixStatus", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableMixLot", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableMixItem", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableKeepZero", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EnableBreakStore", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: false, - defaultValue: true, - oldClrType: typeof(bool), - oldType: "bit", - oldNullable: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.RenameColumn( - name: "EnableWholeStore", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableWholeStore"); - - migrationBuilder.RenameColumn( - name: "EnableSplitPallet", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableSplitPallet"); - - migrationBuilder.RenameColumn( - name: "EnableSplitBox", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableSplitBox"); - - migrationBuilder.RenameColumn( - name: "EnableShip", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableShip"); - - migrationBuilder.RenameColumn( - name: "EnableReturnToSupplier", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableReturnToSupplier"); - - migrationBuilder.RenameColumn( - name: "EnableReturnFromCustomer", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableReturnFromCustomer"); - - migrationBuilder.RenameColumn( - name: "EnableReceive", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableReceive"); - - migrationBuilder.RenameColumn( - name: "EnablePick", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnablePick"); - - migrationBuilder.RenameColumn( - name: "EnableOverPick", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableOverPick"); - - migrationBuilder.RenameColumn( - name: "EnableOpportunityCount", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableOpportunityCount"); - - migrationBuilder.RenameColumn( - name: "EnableNegative", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableNegative"); - - migrationBuilder.RenameColumn( - name: "EnableMixStatus", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableMixStatus"); - - migrationBuilder.RenameColumn( - name: "EnableMixLot", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableMixLot"); - - migrationBuilder.RenameColumn( - name: "EnableMixItem", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableMixItem"); - - migrationBuilder.RenameColumn( - name: "EnableKeepZero", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableKeepZero"); - - migrationBuilder.RenameColumn( - name: "EnableBreakStore", - schema: "dbo", - table: "Basedata_LocationGroup", - newName: "LocSwitch_EnableBreakStore"); - - migrationBuilder.RenameColumn( - name: "EnableWholeStore", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableWholeStore"); - - migrationBuilder.RenameColumn( - name: "EnableSplitPallet", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableSplitPallet"); - - migrationBuilder.RenameColumn( - name: "EnableSplitBox", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableSplitBox"); - - migrationBuilder.RenameColumn( - name: "EnableShip", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableShip"); - - migrationBuilder.RenameColumn( - name: "EnableReturnToSupplier", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableReturnToSupplier"); - - migrationBuilder.RenameColumn( - name: "EnableReturnFromCustomer", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableReturnFromCustomer"); - - migrationBuilder.RenameColumn( - name: "EnableReceive", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableReceive"); - - migrationBuilder.RenameColumn( - name: "EnablePick", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnablePick"); - - migrationBuilder.RenameColumn( - name: "EnableOverPick", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableOverPick"); - - migrationBuilder.RenameColumn( - name: "EnableOpportunityCount", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableOpportunityCount"); - - migrationBuilder.RenameColumn( - name: "EnableNegative", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableNegative"); - - migrationBuilder.RenameColumn( - name: "EnableMixStatus", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableMixStatus"); - - migrationBuilder.RenameColumn( - name: "EnableMixLot", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableMixLot"); - - migrationBuilder.RenameColumn( - name: "EnableMixItem", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableMixItem"); - - migrationBuilder.RenameColumn( - name: "EnableKeepZero", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableKeepZero"); - - migrationBuilder.RenameColumn( - name: "EnableBreakStore", - schema: "dbo", - table: "Basedata_Location", - newName: "LocSwitch_EnableBreakStore"); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableWholeStore", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableSplitPallet", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableSplitBox", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableShip", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableReturnToSupplier", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableReturnFromCustomer", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableReceive", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnablePick", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableOverPick", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableOpportunityCount", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableNegative", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableMixStatus", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableMixLot", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableMixItem", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableKeepZero", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableBreakStore", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableWholeStore", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableSplitPallet", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableSplitBox", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableShip", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableReturnToSupplier", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableReturnFromCustomer", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableReceive", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnablePick", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableOverPick", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableOpportunityCount", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableNegative", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableMixStatus", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableMixLot", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableMixItem", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableKeepZero", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - - migrationBuilder.AlterColumn( - name: "LocSwitch_EnableBreakStore", - schema: "dbo", - table: "Basedata_Location", - type: "bit", - nullable: true, - oldClrType: typeof(bool), - oldType: "bit", - oldDefaultValue: true); - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230110062547_FlatLocation.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230110062547_FlatLocation.Designer.cs deleted file mode 100644 index fb132a2bd..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230110062547_FlatLocation.Designer.cs +++ /dev/null @@ -1,4106 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - [Migration("20230110062547_FlatLocation")] - partial class FlatLocation - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty") - .IsUnique(); - - b.ToTable("Basedata_AQL", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .HasColumnType("int"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Area", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AreaItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Allowed") - .HasColumnType("bit"); - - b.Property("AreaId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UomId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("AreaId", "ItemId") - .IsUnique(); - - b.ToTable("Basedata_AreaItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ComponentQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ComponentUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .HasColumnType("int"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .HasColumnType("int"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Module") - .IsUnique() - .HasFilter("[Module] IS NOT NULL"); - - b.ToTable("Basedata_Calendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Category", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Configuration", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Key") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Key") - .IsUnique(); - - b.ToTable("Basedata_Configuration", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Currency", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Customer", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerBom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ChildItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FailureTime") - .HasColumnType("datetime2"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ParentItemId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CustomerId", "ParentItemId", "ChildItemId") - .IsUnique(); - - b.ToTable("Basedata_CustomerBom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dict", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InterfaceCalendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InventoryRoute", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InventoryRoute", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .HasColumnType("int"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLine") - .HasColumnType("nvarchar(max)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .HasColumnType("int"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CategoryCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "WarehouseCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemSafetyStock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Location", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Machine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Param", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Param", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProdLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ProdLineItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Project", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Route", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Route", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Rule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Rule", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Shift", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Strategy", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Strategy", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StrategyRule", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RuleId") - .HasColumnType("uniqueidentifier"); - - b.Property("Seq") - .HasColumnType("int"); - - b.Property("StrategyId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("StrategyId", "RuleId") - .IsUnique(); - - b.ToTable("Basedata_StrategyRule", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Supplier", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTime", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTime", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Team", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .HasColumnType("int"); - - b.Property("TransType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType") - .IsUnique(); - - b.ToTable("Basedata_TransactionType", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Uom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Warehouse", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkShop", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkStation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemGuideBookId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemGuideBookId"); - - b1.ToTable("Basedata_ItemGuideBook", "dbo"); - - b1.WithOwner() - .HasForeignKey("ItemGuideBookId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230110062547_FlatLocation.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230110062547_FlatLocation.cs deleted file mode 100644 index e40751be1..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230110062547_FlatLocation.cs +++ /dev/null @@ -1,62 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations; - -public partial class FlatLocation : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.RenameColumn( - name: "RawLocation", - schema: "dbo", - table: "Basedata_WorkStation", - newName: "RawLocationCode"); - - migrationBuilder.RenameColumn( - name: "ProductLocation", - schema: "dbo", - table: "Basedata_WorkStation", - newName: "ProductLocationCode"); - - migrationBuilder.RenameColumn( - name: "RawLocation", - schema: "dbo", - table: "Basedata_ProductionLine", - newName: "RawLocationCode"); - - migrationBuilder.RenameColumn( - name: "ProductLocation", - schema: "dbo", - table: "Basedata_ProductionLine", - newName: "ProductLocationCode"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.RenameColumn( - name: "RawLocationCode", - schema: "dbo", - table: "Basedata_WorkStation", - newName: "RawLocation"); - - migrationBuilder.RenameColumn( - name: "ProductLocationCode", - schema: "dbo", - table: "Basedata_WorkStation", - newName: "ProductLocation"); - - migrationBuilder.RenameColumn( - name: "RawLocationCode", - schema: "dbo", - table: "Basedata_ProductionLine", - newName: "RawLocation"); - - migrationBuilder.RenameColumn( - name: "ProductLocationCode", - schema: "dbo", - table: "Basedata_ProductionLine", - newName: "ProductLocation"); - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230111010832_RemoveUseless.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230111010832_RemoveUseless.Designer.cs deleted file mode 100644 index a49468ad9..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230111010832_RemoveUseless.Designer.cs +++ /dev/null @@ -1,3526 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - [Migration("20230111010832_RemoveUseless")] - partial class RemoveUseless - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty") - .IsUnique(); - - b.ToTable("Basedata_AQL", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .HasColumnType("int"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Area", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ComponentQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ComponentUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .HasColumnType("int"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .HasColumnType("int"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Module") - .IsUnique() - .HasFilter("[Module] IS NOT NULL"); - - b.ToTable("Basedata_Calendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Category", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Currency", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Customer", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dict", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InterfaceCalendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .HasColumnType("int"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLine") - .HasColumnType("nvarchar(max)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .HasColumnType("int"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CategoryCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "WarehouseCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemSafetyStock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .HasColumnType("int"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Location", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .HasColumnType("int"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Machine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ProductionLineItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Project", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Shift", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Supplier", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTimeWindow", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTimeWindow", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Team", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .HasColumnType("int"); - - b.Property("TransType") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType") - .IsUnique(); - - b.ToTable("Basedata_TransactionType", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Uom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Warehouse", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkShop", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkStation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemGuideBookId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemGuideBookId"); - - b1.ToTable("Basedata_ItemGuideBook", "dbo"); - - b1.WithOwner() - .HasForeignKey("ItemGuideBookId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230111010832_RemoveUseless.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230111010832_RemoveUseless.cs deleted file mode 100644 index 8d1e3e30b..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230111010832_RemoveUseless.cs +++ /dev/null @@ -1,468 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations; - -public partial class RemoveUseless : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropTable( - name: "Basedata_AreaItem", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_Configuration", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_CustomerBom", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_InventoryRoute", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_Param", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_ProdLineItem", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_Route", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_Rule", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_Strategy", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_StrategyRule", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_SupplierTime", - schema: "dbo"); - - migrationBuilder.CreateTable( - name: "Basedata_ProductionLineItem", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ProdLineCode = table.Column(type: "nvarchar(450)", nullable: false), - ItemCode = table.Column(type: "nvarchar(450)", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ProductionLineItem", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_SupplierTimeWindow", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - TimeSlot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Week = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_SupplierTimeWindow", x => x.Id); - }); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ProductionLineItem_ProdLineCode_ItemCode", - schema: "dbo", - table: "Basedata_ProductionLineItem", - columns: new[] { "ProdLineCode", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SupplierTimeWindow_SupplierCode_TimeSlot_Week", - schema: "dbo", - table: "Basedata_SupplierTimeWindow", - columns: new[] { "SupplierCode", "TimeSlot", "Week" }, - unique: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropTable( - name: "Basedata_ProductionLineItem", - schema: "dbo"); - - migrationBuilder.DropTable( - name: "Basedata_SupplierTimeWindow", - schema: "dbo"); - - migrationBuilder.CreateTable( - name: "Basedata_AreaItem", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Allowed = table.Column(type: "bit", nullable: false), - AreaId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ItemId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - UomId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_AreaItem", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Configuration", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - Key = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Value = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Configuration", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_CustomerBom", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ChildItemId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - CustomerId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - EffectiveTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - FailureTime = table.Column(type: "datetime2", nullable: false), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - ParentItemId = table.Column(type: "uniqueidentifier", maxLength: 64, nullable: false), - Qty = table.Column(type: "decimal(18,6)", nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_CustomerBom", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_InventoryRoute", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_InventoryRoute", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Param", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Enabled = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - Group = table.Column(type: "nvarchar(max)", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Value = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Param", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_ProdLineItem", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(450)", nullable: false), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - ProdLineCode = table.Column(type: "nvarchar(450)", nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_ProdLineItem", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Route", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Route", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Rule", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - Description = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Value = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Rule", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_Strategy", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Code = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - Description = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Type = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_Strategy", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_StrategyRule", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - EffectiveTime = table.Column(type: "datetime2", nullable: false), - ExpireTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - RuleId = table.Column(type: "uniqueidentifier", nullable: false), - Seq = table.Column(type: "int", nullable: false), - StrategyId = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_StrategyRule", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Basedata_SupplierTime", - schema: "dbo", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - TimeSlot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Week = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Basedata_SupplierTime", x => x.Id); - }); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_AreaItem_AreaId_ItemId", - schema: "dbo", - table: "Basedata_AreaItem", - columns: new[] { "AreaId", "ItemId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Configuration_Key", - schema: "dbo", - table: "Basedata_Configuration", - column: "Key", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_CustomerBom_CustomerId_ParentItemId_ChildItemId", - schema: "dbo", - table: "Basedata_CustomerBom", - columns: new[] { "CustomerId", "ParentItemId", "ChildItemId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_InventoryRoute_Code", - schema: "dbo", - table: "Basedata_InventoryRoute", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Param_Code", - schema: "dbo", - table: "Basedata_Param", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_ProdLineItem_ProdLineCode_ItemCode", - schema: "dbo", - table: "Basedata_ProdLineItem", - columns: new[] { "ProdLineCode", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Route_Code", - schema: "dbo", - table: "Basedata_Route", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Rule_Code", - schema: "dbo", - table: "Basedata_Rule", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_Strategy_Code", - schema: "dbo", - table: "Basedata_Strategy", - column: "Code", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_StrategyRule_StrategyId_RuleId", - schema: "dbo", - table: "Basedata_StrategyRule", - columns: new[] { "StrategyId", "RuleId" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Basedata_SupplierTime_SupplierCode_TimeSlot_Week", - schema: "dbo", - table: "Basedata_SupplierTime", - columns: new[] { "SupplierCode", "TimeSlot", "Week" }, - unique: true); - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215005944_EnumToString.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215005944_EnumToString.Designer.cs deleted file mode 100644 index e71470977..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215005944_EnumToString.Designer.cs +++ /dev/null @@ -1,3545 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - [Migration("20230215005944_EnumToString")] - partial class EnumToString - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.13") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty") - .IsUnique(); - - b.ToTable("Basedata_AQL", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Area", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ComponentQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ComponentUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Module") - .IsUnique() - .HasFilter("[Module] IS NOT NULL"); - - b.ToTable("Basedata_Calendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Category", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Currency", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Customer", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dict", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InterfaceCalendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CategoryCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasColumnType("nvarchar(max)"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasDefaultValue("Open"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "WarehouseCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemSafetyStock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Location", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Machine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ProductionLineItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Project", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Shift", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Supplier", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTimeWindow", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTimeWindow", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Team", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TransType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType") - .IsUnique(); - - b.ToTable("Basedata_TransactionType", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Uom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Warehouse", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkShop", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkStation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215005944_EnumToString.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215005944_EnumToString.cs deleted file mode 100644 index 4014d749b..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215005944_EnumToString.cs +++ /dev/null @@ -1,883 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations -{ - public partial class EnumToString : Migration - { - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "ProductLine", - schema: "dbo", - table: "Basedata_ItemBasic"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - schema: "dbo", - table: "Basedata_ItemGuideBook", - newName: "Name"); - - migrationBuilder.RenameColumn( - name: "Item_Desc2", - schema: "dbo", - table: "Basedata_ItemGuideBook", - newName: "Desc2"); - - migrationBuilder.RenameColumn( - name: "Item_Desc1", - schema: "dbo", - table: "Basedata_ItemGuideBook", - newName: "Desc1"); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_WorkStation", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(int), - oldType: "int", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_WorkGroup", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_Uom", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Uom", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "TransType", - schema: "dbo", - table: "Basedata_TransactionType", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "TransSubType", - schema: "dbo", - table: "Basedata_TransactionType", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_Supplier", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Project", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_ProductionLine", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "GroupType", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "DefaultInventoryStatus", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_Location", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Location", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "DefaultInventoryStatus", - schema: "dbo", - table: "Basedata_Location", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "StoreRelationType", - schema: "dbo", - table: "Basedata_ItemStoreRelation", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "PramaryUM", - schema: "dbo", - table: "Basedata_ItemStoreRelation", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "StoreRelationType", - schema: "dbo", - table: "Basedata_ItemSafetyStock", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - schema: "dbo", - table: "Basedata_ItemQuality", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "Open", - oldClrType: typeof(int), - oldType: "int", - oldDefaultValue: 1); - - migrationBuilder.AlterColumn( - name: "InspectType", - schema: "dbo", - table: "Basedata_ItemQuality", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_ItemQuality", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Name", - schema: "dbo", - table: "Basedata_ItemGuideBook", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Desc2", - schema: "dbo", - table: "Basedata_ItemGuideBook", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Desc1", - schema: "dbo", - table: "Basedata_ItemGuideBook", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ValidityUnit", - schema: "dbo", - table: "Basedata_ItemBasic", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - schema: "dbo", - table: "Basedata_ItemBasic", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ManageType", - schema: "dbo", - table: "Basedata_ItemBasic", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_ErpLocation", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Dock", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_Customer", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ShortName", - schema: "dbo", - table: "Basedata_Customer", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Category", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Status", - schema: "dbo", - table: "Basedata_Calendar", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "TruncType", - schema: "dbo", - table: "Basedata_Bom", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "PlannedSplitRule", - schema: "dbo", - table: "Basedata_Bom", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "DistributionType", - schema: "dbo", - table: "Basedata_Bom", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Area", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "AreaType", - schema: "dbo", - table: "Basedata_Area", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.RenameColumn( - name: "Name", - schema: "dbo", - table: "Basedata_ItemGuideBook", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "Desc2", - schema: "dbo", - table: "Basedata_ItemGuideBook", - newName: "Item_Desc2"); - - migrationBuilder.RenameColumn( - name: "Desc1", - schema: "dbo", - table: "Basedata_ItemGuideBook", - newName: "Item_Desc1"); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_WorkStation", - type: "int", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_WorkGroup", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_Uom", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Uom", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "TransType", - schema: "dbo", - table: "Basedata_TransactionType", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "TransSubType", - schema: "dbo", - table: "Basedata_TransactionType", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_Supplier", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Project", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_ProductionLine", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "GroupType", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "DefaultInventoryStatus", - schema: "dbo", - table: "Basedata_LocationGroup", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_Location", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Location", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "DefaultInventoryStatus", - schema: "dbo", - table: "Basedata_Location", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "StoreRelationType", - schema: "dbo", - table: "Basedata_ItemStoreRelation", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "PramaryUM", - schema: "dbo", - table: "Basedata_ItemStoreRelation", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "StoreRelationType", - schema: "dbo", - table: "Basedata_ItemSafetyStock", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - schema: "dbo", - table: "Basedata_ItemQuality", - type: "int", - nullable: false, - defaultValue: 1, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "Open"); - - migrationBuilder.AlterColumn( - name: "InspectType", - schema: "dbo", - table: "Basedata_ItemQuality", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_ItemQuality", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - schema: "dbo", - table: "Basedata_ItemGuideBook", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - schema: "dbo", - table: "Basedata_ItemGuideBook", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - schema: "dbo", - table: "Basedata_ItemGuideBook", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ValidityUnit", - schema: "dbo", - table: "Basedata_ItemBasic", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - schema: "dbo", - table: "Basedata_ItemBasic", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ManageType", - schema: "dbo", - table: "Basedata_ItemBasic", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "ProductLine", - schema: "dbo", - table: "Basedata_ItemBasic", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_ErpLocation", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Dock", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Type", - schema: "dbo", - table: "Basedata_Customer", - type: "int", - maxLength: 64, - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ShortName", - schema: "dbo", - table: "Basedata_Customer", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Category", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Status", - schema: "dbo", - table: "Basedata_Calendar", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "TruncType", - schema: "dbo", - table: "Basedata_Bom", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "PlannedSplitRule", - schema: "dbo", - table: "Basedata_Bom", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "DistributionType", - schema: "dbo", - table: "Basedata_Bom", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Description", - schema: "dbo", - table: "Basedata_Area", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "AreaType", - schema: "dbo", - table: "Basedata_Area", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215071620_BasedataEnumToString.Designer.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215071620_BasedataEnumToString.Designer.cs deleted file mode 100644 index 9c93704a2..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215071620_BasedataEnumToString.Designer.cs +++ /dev/null @@ -1,3543 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - [Migration("20230215071620_BasedataEnumToString")] - partial class BasedataEnumToString - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.13") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty") - .IsUnique(); - - b.ToTable("Basedata_AQL", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Area", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ComponentQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ComponentUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Module") - .IsUnique() - .HasFilter("[Module] IS NOT NULL"); - - b.ToTable("Basedata_Calendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Category", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Currency", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Customer", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dict", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InterfaceCalendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CategoryCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasColumnType("nvarchar(max)"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "WarehouseCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemSafetyStock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Location", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Machine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ProductionLineItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Project", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Shift", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Supplier", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTimeWindow", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTimeWindow", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Team", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TransType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType") - .IsUnique(); - - b.ToTable("Basedata_TransactionType", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Uom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Warehouse", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkShop", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkStation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215071620_BasedataEnumToString.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215071620_BasedataEnumToString.cs deleted file mode 100644 index e9e1f9cd0..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/20230215071620_BasedataEnumToString.cs +++ /dev/null @@ -1,39 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations -{ - public partial class BasedataEnumToString : Migration - { - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.AlterColumn( - name: "Status", - schema: "dbo", - table: "Basedata_ItemQuality", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "Open"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.AlterColumn( - name: "Status", - schema: "dbo", - table: "Basedata_ItemQuality", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "Open", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/BasedataDbContextModelSnapshot.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/BasedataDbContextModelSnapshot.cs deleted file mode 100644 index b7215e09b..000000000 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/Migrations/BasedataDbContextModelSnapshot.cs +++ /dev/null @@ -1,3541 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Basedata.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Basedata.Migrations -{ - [DbContext(typeof(BasedataDbContext))] - partial class BasedataDbContextModelSnapshot : ModelSnapshot - { - protected override void BuildModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.13") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.AQL", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CeilingQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FloorQty") - .HasColumnType("decimal(18,6)"); - - b.Property("IsUsePercent") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("SampleQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode", "FloorQty") - .IsUnique(); - - b.ToTable("Basedata_AQL", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Area", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFunctional") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Area", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Bom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Component") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ComponentQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ComponentUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DistributionType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ERPOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Layer") - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("MFGOp") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlannedSplitRule") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Product") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TruncType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Product", "Component") - .IsUnique(); - - b.ToTable("Basedata_Bom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Calendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Module") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Module") - .IsUnique() - .HasFilter("[Module] IS NOT NULL"); - - b.ToTable("Basedata_Calendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Category", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Category", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Currency", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsBasicCurrency") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Currency", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CurrencyExchange", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicCurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasColumnType("uniqueidentifier"); - - b.Property("EfficetiveTime") - .HasColumnType("datetime2"); - - b.Property("ExpireTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Rate") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("CurrencyId", "BasicCurrencyId") - .IsUnique(); - - b.ToTable("Basedata_CurrencyExchange", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Customer", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Customer", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerAddress", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contact") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Desc") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerAddress", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.CustomerItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_CustomerItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dict", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterId") - .HasColumnType("uniqueidentifier"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterId"); - - b.ToTable("Basedata_DictItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Dock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DocumentSetting", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberFormat") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberPrefix") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSeparator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("NumberSerialLength") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransactionType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_DocumentSetting", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ErpLocation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ErpLocation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.InterfaceCalendar", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConvertToTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Month") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_InterfaceCalendar", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemBasic", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BasicUom") - .HasColumnType("nvarchar(max)"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("CanOutsourcing") - .HasColumnType("bit"); - - b.Property("Category") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Color") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Eco") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Elevel") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsPhantom") - .HasColumnType("bit"); - - b.Property("IsRecycled") - .HasColumnType("bit"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ManageType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Project") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Validity") - .HasColumnType("int"); - - b.Property("ValidityUnit") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ItemBasic", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemCategory", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CategoryCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Value") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.HasKey("Id"); - - b.HasIndex("CategoryCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemCategory", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemGuideBook", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasColumnType("nvarchar(max)"); - - b.Property("PictureBlobName") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Step") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ItemGuideBook", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemPack", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BasicUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("PackCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "PackCode") - .IsUnique(); - - b.ToTable("Basedata_ItemPack", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemQuality", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "SupplierCode") - .IsUnique(); - - b.ToTable("Basedata_ItemQuality", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemSafetyStock", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FeedLine") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FeedUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaxStock") - .HasColumnType("decimal(18,6)"); - - b.Property("MinStock") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SafetyStock") - .HasColumnType("decimal(18,6)"); - - b.Property("StoreRelationType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "WarehouseCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemSafetyStock", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ItemStoreRelation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AltUm") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AltUmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsFixed") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MultiLoc") - .HasColumnType("int"); - - b.Property("PramaryUM") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StoreRelationType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreUM") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StoreValue") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UmQty") - .HasColumnType("decimal(18,6)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode", "StoreRelationType", "StoreValue") - .IsUnique() - .HasFilter("[StoreValue] IS NOT NULL"); - - b.ToTable("Basedata_ItemStoreRelation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Location", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ColumnCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ErpLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickOrder") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowCode") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("ShelfCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroupCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Location", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.LocationGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DefaultInventoryStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EnableBreakStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableKeepZero") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixItem") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixLot") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableMixStatus") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableNegative") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOpportunityCount") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableOverPick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnablePick") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReceive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnFromCustomer") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableReturnToSupplier") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableShip") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitBox") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableSplitPallet") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("EnableWholeStore") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("GroupType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OverflowLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PickPriority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_LocationGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Machine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLineId") - .HasColumnType("uniqueidentifier"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStationId") - .HasColumnType("uniqueidentifier"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Machine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLine", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkshopCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_ProductionLine", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.ProductionLineItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("ProdLineCode") - .IsRequired() - .HasColumnType("nvarchar(450)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("ProdLineCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_ProductionLineItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Project", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Project", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.PurchasePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_PurchasePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SalePriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("CustomerId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "CustomerId") - .IsUnique(); - - b.ToTable("Basedata_SalePriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Shift", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("EndAtNextDay") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Shift", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.StdCostPriceSheet", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CurrencyId") - .HasMaxLength(64) - .HasColumnType("uniqueidentifier"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierId") - .HasColumnType("uniqueidentifier"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code", "SupplierId") - .IsUnique(); - - b.ToTable("Basedata_StdCostPriceSheet", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Supplier", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Address") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("Bank") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("City") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Contacts") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Country") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Currency") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("Fax") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsActive") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(true); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PostID") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ShortName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Supplier", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierItem", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("QtyPerPallet") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierSimpleName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "ItemCode") - .IsUnique(); - - b.ToTable("Basedata_SupplierItem", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.SupplierTimeWindow", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeSlot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Week") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode", "TimeSlot", "Week") - .IsUnique(); - - b.ToTable("Basedata_SupplierTimeWindow", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Team", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Members") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Team", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.TransactionType", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AutoAgreeRequest") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandleRequest") - .HasColumnType("bit"); - - b.Property("AutoSubmitRequest") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .IsRequired() - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("Enabled") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("InLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("OutInventoryStatuses") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OutLocationAreas") - .HasColumnType("nvarchar(max)"); - - b.Property("OutLocationTypes") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransSubType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TransType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("TransType", "TransSubType") - .IsUnique(); - - b.ToTable("Basedata_TransactionType", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Uom", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Uom", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Warehouse", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_Warehouse", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkGroup", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkGroup", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkShop", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkShop", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.WorkStation", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Code") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionLineCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Code") - .IsUnique(); - - b.ToTable("Basedata_WorkStation", "dbo"); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.DictItem", b => - { - b.HasOne("Win_in.Sfs.Basedata.Domain.Dict", null) - .WithMany("Items") - .HasForeignKey("MasterId") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Basedata.Domain.Dict", b => - { - b.Navigation("Items"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PositionCode/PositionCodeDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PositionCode/PositionCodeDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..33f7bd550 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PositionCode/PositionCodeDbContextModelCreatingExtensions.cs @@ -0,0 +1,40 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.EntityFrameworkCore; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public static class PositionCodeDbContextModelCreatingExtensions +{ + public static void ConfigurePositionCode(this ModelBuilder builder, BasedataModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(PositionCode), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + + //Properties + b.Property(q => q.Code).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + + b.Property(q => q.LocationCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.PartCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.PartName).HasMaxLength(SfsPropertyConst.NameLength); + b.Property(q => q.LocationName).HasMaxLength(SfsPropertyConst.NameLength); + b.Property(q => q.Type).HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); + + //Relations + //None + + //Indexes + b.HasIndex(q => new { q.Code,q.PartCode,q.LocationCode }).IsUnique(); + b.HasIndex(q => new { q.Code }).IsUnique(); + b.HasIndex(q => new { q.PartCode }).IsUnique(); + }); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PositionCode/PositionCodeEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PositionCode/PositionCodeEfCoreRepository.cs new file mode 100644 index 000000000..e3d8a8d42 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PositionCode/PositionCodeEfCoreRepository.cs @@ -0,0 +1,12 @@ +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public class PositionCodeEfCoreRepository : SfsBaseDataEfCoreRepositoryBase, IPositionCodeRepository, ISfsBulkRepositoryBase +{ + public PositionCodeEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PurchasePrices/PurchasePriceSheetDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PurchasePrices/PurchasePriceSheetDbContextModelCreatingExtensions.cs index b472310e5..05f3b5f56 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PurchasePrices/PurchasePriceSheetDbContextModelCreatingExtensions.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PurchasePrices/PurchasePriceSheetDbContextModelCreatingExtensions.cs @@ -20,17 +20,15 @@ public static class PurchasePriceSheetDbContextModelCreatingExtensions b.ConfigureSfsBase(); //Properties - b.Property(q => q.Code).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); - b.Property(q => q.Name).HasMaxLength(SfsPropertyConst.NameLength); + b.Property(q => q.ItemCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.SupplierCode).HasMaxLength(SfsPropertyConst.CodeLength); b.Property(q => q.Description).HasMaxLength(SfsPropertyConst.DescLength); - b.Property(x => x.SupplierId).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); - b.Property(x => x.CurrencyId).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); //Relations //None //Indexes - b.HasIndex(q => new { q.Code }).IsUnique(); + b.HasIndex(q => new { q.ItemCode ,q.SupplierCode}).IsUnique(); }); } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PurchasePrices/PurchasePriceSheetEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PurchasePrices/PurchasePriceSheetEfCoreRepository.cs index c6fd3ff7e..9e13ab91e 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PurchasePrices/PurchasePriceSheetEfCoreRepository.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/PurchasePrices/PurchasePriceSheetEfCoreRepository.cs @@ -1,3 +1,6 @@ +using Microsoft.EntityFrameworkCore; +using System.Threading.Tasks; +using System; using Volo.Abp.EntityFrameworkCore; using Win_in.Sfs.Basedata.Domain; @@ -9,4 +12,20 @@ public class PurchasePriceSheetEfCoreRepository : SfsBaseDataEfCoreRepositoryBas { } + + public virtual async Task UpsertAsyncByInterface(PurchasePriceSheet entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + var exist = await dbSet.FirstOrDefaultAsync(p => p.ItemCode == entity.ItemCode&& p.SupplierCode == entity.SupplierCode).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + } + else + { + exist.PurchasePrice = entity.PurchasePrice; + exist.Description = entity.Description; + exist.LastModificationTime = DateTime.Now; + } + } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SalePrices/SalePriceSheetDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SalePrices/SalePriceSheetDbContextModelCreatingExtensions.cs index 34269f448..9babd45a6 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SalePrices/SalePriceSheetDbContextModelCreatingExtensions.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SalePrices/SalePriceSheetDbContextModelCreatingExtensions.cs @@ -20,17 +20,15 @@ public static class SalePriceSheetDbContextModelCreatingExtensions b.ConfigureSfsBase(); //Properties - b.Property(q => q.Code).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); - b.Property(q => q.Name).HasMaxLength(SfsPropertyConst.NameLength); + b.Property(q => q.ItemCode).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.CustomerCode).HasMaxLength(SfsPropertyConst.CodeLength); b.Property(q => q.Description).HasMaxLength(SfsPropertyConst.DescLength); - b.Property(x => x.CustomerId).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); - b.Property(x => x.CurrencyId).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); //Relations //None //Indexes - b.HasIndex(q => new { q.Code, q.CustomerId }).IsUnique(); + b.HasIndex(q => new { q.CustomerCode, q.ItemCode }).IsUnique(); }); } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SalePrices/SalePriceSheetEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SalePrices/SalePriceSheetEfCoreRepository.cs index bc667d6ab..2df8da08b 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SalePrices/SalePriceSheetEfCoreRepository.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SalePrices/SalePriceSheetEfCoreRepository.cs @@ -1,3 +1,6 @@ +using Microsoft.EntityFrameworkCore; +using System.Threading.Tasks; +using System; using Volo.Abp.EntityFrameworkCore; using Win_in.Sfs.Basedata.Domain; @@ -9,4 +12,19 @@ public class SalePriceSheetEfCoreRepository : SfsBaseDataEfCoreRepositoryBase p.ItemCode == entity.ItemCode && p.CustomerCode == entity.CustomerCode).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + } + else + { + exist.SalePrice = entity.SalePrice; + exist.Description = entity.Description; + exist.LastModificationTime = DateTime.Now; + } + } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SplitPackings/SplitPackingRecDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SplitPackings/SplitPackingRecDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..db760c765 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SplitPackings/SplitPackingRecDbContextModelCreatingExtensions.cs @@ -0,0 +1,54 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public static class SplitPackingRecDbContextModelCreatingExtensions +{ + public static void ConfigureSplitPackingRec(this ModelBuilder builder, BasedataModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(SplitPackingRec), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + //b.ConfigureSfsBase(); + + //Properties + b.Property(q => q.OprType).IsRequired(); + b.Property(q => q.FromPackingCode).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.FromTopPackingCode).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.FromStdPackQty).IsRequired(); + b.Property(q => q.FromUom).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.FromQty).IsRequired().HasPrecision(18, 6); + + b.Property(q => q.ToPackingCode).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ToTopPackingCode).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ToStdPackQty).IsRequired(); + b.Property(q => q.ToUom).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ToQty).IsRequired().HasPrecision(18, 6); + + b.Property(q => q.ItemCode).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ItemName).HasMaxLength(SfsPropertyConst.NameLength); + b.Property(q => q.ItemDesc1).HasMaxLength(SfsPropertyConst.DescLength); + b.Property(q => q.ItemDesc2).HasMaxLength(SfsPropertyConst.DescLength); + b.Property(q => q.FromLot).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ToLot).HasMaxLength(SfsPropertyConst.CodeLength); + + b.Property(q => q.PurchaseInfo_PoNumber).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.PurchaseInfo_AsnNumber).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ArrivalNoticNumber).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.TaskOrderNumber).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ReceiptRecNumber).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.PutOnShelfNumber).HasMaxLength(SfsPropertyConst.CodeLength); + + //Indexes + b.HasIndex(q => new { FromPackingCode = q.FromPackingCode, ToPackingCode = q.ToPackingCode }); + b.HasIndex(q => new { ToPackingCode = q.ToPackingCode }); + }); + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SplitPackings/SplitPackingRecEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SplitPackings/SplitPackingRecEfCoreRepository.cs new file mode 100644 index 000000000..a3929a478 --- /dev/null +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/SplitPackings/SplitPackingRecEfCoreRepository.cs @@ -0,0 +1,11 @@ +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Basedata.Domain; + +namespace Win_in.Sfs.Basedata.EntityFrameworkCore; + +public class SplitPackingRecEfCoreRepository : SfsBaseDataEfCoreRepositoryBase, ISplitPackingRecRepository +{ + public SplitPackingRecEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } +} diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/StdCostPrices/StdCostPriceSheetDbContextModelCreatingExtensions.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/StdCostPrices/StdCostPriceSheetDbContextModelCreatingExtensions.cs index 2ba5ff3cb..36015bc33 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/StdCostPrices/StdCostPriceSheetDbContextModelCreatingExtensions.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/StdCostPrices/StdCostPriceSheetDbContextModelCreatingExtensions.cs @@ -16,13 +16,12 @@ public static class StdCostPriceSheetDbContextModelCreatingExtensions b.ConfigureByConvention(); b.ConfigureSfsBase(); - b.Property(x => x.SupplierId).IsRequired(); - b.Property(x => x.Code).IsRequired().HasMaxLength(SfsEfCorePropertyConst.CodeLength); - b.Property(x => x.Name).IsRequired().HasMaxLength(SfsEfCorePropertyConst.NameLength); + + b.Property(x => x.ItemCode).IsRequired().HasMaxLength(SfsEfCorePropertyConst.CodeLength); + b.Property(x => x.Description).HasMaxLength(SfsEfCorePropertyConst.DescLength); - b.Property(x => x.CurrencyId).HasMaxLength(SfsEfCorePropertyConst.NameLength); - b.HasIndex(x => new { x.Code, x.SupplierId }).IsUnique(); + b.HasIndex(x => new { x.ItemCode}).IsUnique(); }); } } diff --git a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/StdCostPrices/StdCostPriceSheetEfCoreRepository.cs b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/StdCostPrices/StdCostPriceSheetEfCoreRepository.cs index 16b2c7bca..968856d73 100644 --- a/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/StdCostPrices/StdCostPriceSheetEfCoreRepository.cs +++ b/be/Modules/BaseData/src/Win_in.Sfs.Basedata.EntityFrameworkCore/StdCostPrices/StdCostPriceSheetEfCoreRepository.cs @@ -1,3 +1,6 @@ +using Microsoft.EntityFrameworkCore; +using System.Threading.Tasks; +using System; using Volo.Abp.EntityFrameworkCore; using Win_in.Sfs.Basedata.Domain; @@ -8,4 +11,19 @@ public class StdCostPriceSheetEfCoreRepository : SfsBaseDataEfCoreRepositoryBase public StdCostPriceSheetEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) { } + public virtual async Task UpsertAsyncByInterface(StdCostPriceSheet entity) + { + var dbSet = await GetDbSetAsync().ConfigureAwait(false); + var exist = await dbSet.FirstOrDefaultAsync(p => p.ItemCode == entity.ItemCode).ConfigureAwait(false); + if (exist == null) + { + var insRet = await InsertAsync(entity).ConfigureAwait(false); + } + else + { + exist.StdCostPrice = entity.StdCostPrice; + exist.Description = entity.Description; + exist.LastModificationTime = DateTime.Now; + } + } } diff --git a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Balances/DTOs/BalanceDTO.cs b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Balances/DTOs/BalanceDTO.cs index 108026c59..bcbd6f810 100644 --- a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Balances/DTOs/BalanceDTO.cs +++ b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Balances/DTOs/BalanceDTO.cs @@ -212,5 +212,18 @@ public class BalanceDTO : SfsBasicDTOBase /// [Display(Name = "最后事务号")] public string LastTransNumber { get; set; } + /// + /// 标准成本单价 + /// + [Display(Name = "标准成本单价")] + public decimal StdCostPrice { get; set; } + /// + /// 标准成本价格 + /// + [Display(Name = "标准成本价格")] + public decimal StdCost + { + get { return StdCostPrice *Qty; } + } } diff --git a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Balances/IBalanceAppService.cs b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Balances/IBalanceAppService.cs index 57c5febea..811bd981f 100644 --- a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Balances/IBalanceAppService.cs +++ b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Balances/IBalanceAppService.cs @@ -165,4 +165,5 @@ public interface IBalanceAppService /// Task> GetListByErpLocationCodeAndItemCodeAsync(string erplocationCode, string itemCode); Task> GetRecommendBalancesByLocationsAsync(RecommendBalanceRequestInput input); + Task> GetBalancePagedListByFilterAsync(SfsInventoryRequestInputBase sfsRequestInput, bool includeDetails = false, CancellationToken cancellationToken = default); } diff --git a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/ExpectOuts/IExpectOutAppService.cs b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/ExpectOuts/IExpectOutAppService.cs index 6ce12eb30..31ae65e93 100644 --- a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/ExpectOuts/IExpectOutAppService.cs +++ b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/ExpectOuts/IExpectOutAppService.cs @@ -1,5 +1,6 @@ using System.Collections.Generic; using System.Threading.Tasks; +using Win_in.Sfs.Basedata.SplitPackings.Commons; using Win_in.Sfs.Shared.Domain.Shared; namespace Win_in.Sfs.Wms.Inventory.Application.Contracts; @@ -29,4 +30,17 @@ public interface IExpectOutAppService string packingCode, EnumInventoryStatus enumInventoryStatus, string lot); + + /// + /// 保存拆箱时涉及的明细修改 + /// + /// + Task> SaveDetail_SplitPackingAsync(SplitPacking_UpdateDetailInput input); + + /// + /// 根据任务号、箱码、数量、库位取预计出列表 + /// + /// + Task> GetListByJobNumberAsync(SplitPacking_UpdateDetailInput input); + } diff --git a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Transactions/ITransactionAppService.cs b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Transactions/ITransactionAppService.cs index bdf2d544a..47ad791b6 100644 --- a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Transactions/ITransactionAppService.cs +++ b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application.Contracts/Transactions/ITransactionAppService.cs @@ -10,6 +10,8 @@ public interface ITransactionAppService Task> AddManyAsync(List inputs); + Task> AddManyEmptyAsync(List inputs); + Task> GetListByNumberAsync(string number); Task> GetListByPackingAsync(string packingCode); Task> GetListByContainerAsync(string containerCode); diff --git a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Balances/BalanceAppService.cs b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Balances/BalanceAppService.cs index 08efeb97e..a8408e666 100644 --- a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Balances/BalanceAppService.cs +++ b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Balances/BalanceAppService.cs @@ -10,6 +10,7 @@ using Microsoft.AspNetCore.Mvc; using Microsoft.Extensions.Logging; using Volo.Abp; using Volo.Abp.Application.Dtos; +using Volo.Abp.Domain.Entities.Events.Distributed; using Volo.Abp.Domain.Repositories; using Win_in.Sfs.Basedata.Application.Contracts; using Win_in.Sfs.Shared.Application.Contracts; @@ -40,6 +41,7 @@ public class BalanceAppService private readonly ITransferLogManager _transferLogManager; private readonly IBalanceManager _balanceManager; private readonly IItemBasicAppService _itemBasicAppService; + private readonly IStdCostPriceSheetAppService _stdCostPriceSheetAppService; public BalanceAppService( IBalanceRepository repository, @@ -47,7 +49,8 @@ public class BalanceAppService IBalanceManager balanceManager, ILocationAclService locationAclService, IItemBasicAclService itemBasicAclService, - IItemBasicAppService itemBasicAppService) : base(repository) + IItemBasicAppService itemBasicAppService, + IStdCostPriceSheetAppService stdCostPriceSheetAppService) : base(repository) { _repository = repository; _transferLogManager = transferLogManager; @@ -55,10 +58,11 @@ public class BalanceAppService _locationAclService = locationAclService; _itemBasicAclService = itemBasicAclService; _itemBasicAppService = itemBasicAppService; + _stdCostPriceSheetAppService= stdCostPriceSheetAppService; } #region Update - + /// /// 修改批次 /// @@ -254,7 +258,25 @@ public class BalanceAppService #endregion Update #region Get - + /// + /// 获取库存余额带标准价格得 + /// + /// + /// + /// + /// + [HttpPost("get-list")] + public virtual async Task> GetBalancePagedListByFilterAsync(SfsInventoryRequestInputBase sfsRequestInput, bool includeDetails = false, + CancellationToken cancellationToken = default) + { + var result =await base.GetPagedListByFilterAsync(sfsRequestInput, includeDetails, cancellationToken); + foreach (var item in result.Items) + { + var std = await _stdCostPriceSheetAppService.GetByItemCode(item.ItemCode).ConfigureAwait(false); + item.StdCostPrice = std == null ? 0 : std.StdCostPrice; + } + return result; + } /// /// /// diff --git a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Balances/BalanceAutoMapperProfile.cs b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Balances/BalanceAutoMapperProfile.cs index 2643d78fc..68722ee3e 100644 --- a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Balances/BalanceAutoMapperProfile.cs +++ b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Balances/BalanceAutoMapperProfile.cs @@ -10,7 +10,9 @@ public partial class InventoryApplicationAutoMapperProfile : Profile private void BalanceAutoMapperProfile() { CreateMap() - .Ignore(x => x.Configuration); + .Ignore(x => x.Configuration) + .Ignore(x => x.StdCostPrice) + .Ignore(x => x.StdCost); CreateMap(); CreateMap(); diff --git a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/ExpectOuts/ExpectOutAppService.cs b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/ExpectOuts/ExpectOutAppService.cs index 5125a0034..fb64edbd3 100644 --- a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/ExpectOuts/ExpectOutAppService.cs +++ b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/ExpectOuts/ExpectOutAppService.cs @@ -6,6 +6,8 @@ using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Volo.Abp; using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Basedata.SplitPackings.Commons; using Win_in.Sfs.Shared.Application.Contracts; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.Inventory.Application.Contracts; @@ -179,4 +181,55 @@ public class ExpectOutAppService return ObjectMapper.Map, List>(entitys); } + + /// + /// 保存拆箱时涉及的明细修改 + /// + /// + [HttpPost("save-detail-split-packing")] + public virtual async Task> SaveDetail_SplitPackingAsync(SplitPacking_UpdateDetailInput input) + { + var lst = await ListByJobNumberAsync(input).ConfigureAwait(false); + if (lst == null || lst.Count == 0) + { + throw new UserFriendlyException($"预计出表没有数据:JobNumber={input.Number}|PackingCode={input.FromPackingCode}|Qty={input.FromQty}|LocationCode={input.FromLocationCode}"); + } + if (lst.Count > 1) + { + throw new UserFriendlyException($"预计出表取到多条数据,应该取到一条数据:JobNumber={input.Number}|PackingCode={input.FromPackingCode}|Qty={input.FromQty}|LocationCode={input.FromLocationCode}"); + } + var obj = lst[0]; + //插入目标箱 + var newObj = CommonHelper.CloneObj(obj); + newObj.SetId(GuidGenerator.Create()); + newObj.PackingCode = input.ToPackingCode; + newObj.Qty = input.ToQty; + var insRet = await _repository.InsertAsync(newObj).ConfigureAwait(false); + //修改源箱 + obj.Qty = input.FromQty - input.ToQty; + var updRet = await _repository.UpdateAsync(obj).ConfigureAwait(false); + List list = new List(); + list.Add(insRet); + list.Add(updRet); + var ret = ObjectMapper.Map, List>(list); + return ret; + } + + + /// + /// 根据任务号、箱码、数量、库位取预计出列表 + /// + /// + [HttpPost("get-list-by-job-number")] + public virtual async Task> GetListByJobNumberAsync(SplitPacking_UpdateDetailInput input) + { + var lst = await ListByJobNumberAsync(input).ConfigureAwait(false); + var ret = ObjectMapper.Map, List>(lst); + return ret; + } + + private async Task> ListByJobNumberAsync(SplitPacking_UpdateDetailInput input) + { + return await _repository.GetListAsync(p => p.JobNumber == input.Number && p.PackingCode == input.FromPackingCode && p.Qty == input.FromQty && p.LocationCode == input.FromLocationCode).ConfigureAwait(false); + } } diff --git a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Transactions/TransactionAppService.cs b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Transactions/TransactionAppService.cs index 561f462db..274977bc1 100644 --- a/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Transactions/TransactionAppService.cs +++ b/be/Modules/Inventory/src/Win_in.Sfs.Wms.Inventory.Application/Transactions/TransactionAppService.cs @@ -87,6 +87,28 @@ public class TransactionAppService return dto; } + [HttpPost("add-many-empty")] + public virtual async Task> AddManyEmptyAsync(List inputs) + { + var entities = ObjectMapper.Map, List>(inputs); + foreach (var entity in entities) + { + if (string.IsNullOrEmpty(entity.Worker)) + { + entity.Worker = CurrentUser.GetUserName(); + } + + entity.TransTime = Clock.Now; + entity.ActiveDate = await _interfaceCalendarAclService.GetActiveDateAsync(Clock.Now).ConfigureAwait(false); + } + //添加库存信息具体方法,会自动添加或者更新 + await _transactionManager.AddManyAsync(entities).ConfigureAwait(false); + //domain层的实体 转化为 显示DTO + var dto = ObjectMapper.Map, List>(entities); + + return dto; + } + [HttpGet("list/by-number/{number}")] public virtual async Task> GetListByNumberAsync(string number) { diff --git a/be/Modules/Label/src/Win_in.Sfs.Label.Application.Contracts/InventoryLabels/IInventoryLabelAppService.cs b/be/Modules/Label/src/Win_in.Sfs.Label.Application.Contracts/InventoryLabels/IInventoryLabelAppService.cs index 406c140fa..069f4dc1f 100644 --- a/be/Modules/Label/src/Win_in.Sfs.Label.Application.Contracts/InventoryLabels/IInventoryLabelAppService.cs +++ b/be/Modules/Label/src/Win_in.Sfs.Label.Application.Contracts/InventoryLabels/IInventoryLabelAppService.cs @@ -20,4 +20,12 @@ public interface IInventoryLabelAppService /// /// Task> CreateManyByNoCodeAsync(List inputs); + + /// + /// Code需要自己生成 传入 否则无法赋值 完整条码 + /// + /// + /// + Task> CreateManyByNoCode_NewAsync(List inputs); + } diff --git a/be/Modules/Label/src/Win_in.Sfs.Label.Application/InventoryLabels/InventoryLabelAppService.cs b/be/Modules/Label/src/Win_in.Sfs.Label.Application/InventoryLabels/InventoryLabelAppService.cs index 815acff1a..4e503bc23 100644 --- a/be/Modules/Label/src/Win_in.Sfs.Label.Application/InventoryLabels/InventoryLabelAppService.cs +++ b/be/Modules/Label/src/Win_in.Sfs.Label.Application/InventoryLabels/InventoryLabelAppService.cs @@ -12,6 +12,7 @@ using Volo.Abp.Domain.Repositories; using Volo.Abp.ObjectMapping; using Volo.Abp.Uow; using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain.Shared; using Win_in.Sfs.Label.Application.Contracts; using Win_in.Sfs.Label.Domain; using Win_in.Sfs.Label.Domain.Shared; @@ -37,6 +38,8 @@ public class InventoryLabelAppService private readonly ISupplierAppService _supplierAppService; private readonly ISupplierItemAppService _supplierItemAppService; private readonly IItemBasicAppService _itemBasicAppService; + private readonly ISplitPackingRecAppService _splitPackingRecAppService; + public InventoryLabelAppService( IInventoryLabelRepository repository, ILabelDefinitionManager labelDefinitionManager @@ -44,6 +47,7 @@ public class InventoryLabelAppService , IItemPackAppService itemPackAppService , ISupplierItemAppService supplierItemAppService , IItemBasicAppService itemBasicAppService + , ISplitPackingRecAppService splitPackingRecAppService ) : base(repository) { _repository = repository; @@ -52,6 +56,7 @@ public class InventoryLabelAppService _itemPackAppService = itemPackAppService; _supplierItemAppService = supplierItemAppService; _itemBasicAppService = itemBasicAppService; + _splitPackingRecAppService = splitPackingRecAppService; } [HttpPost("")] @@ -133,6 +138,60 @@ public class InventoryLabelAppService return ObjectMapper.Map, List>(entitys); } + /// + /// EOF系统接口 + /// 插入箱码记录表、插入拆箱记录表 + /// 是客户箱码,不需要LabelDefine + /// + /// + /// + [HttpPost("create-many-no-code-new")] + [UnitOfWork] + public virtual async Task> CreateManyByNoCode_NewAsync(List inputs) + { + #region 插入拆箱记录表 + foreach (var inputObj in inputs) + { + List recLst = new List(); + SplitPackingRecEditInput packRec = new SplitPackingRecEditInput(); + packRec.OprType = OprTypeEnum.Other; + packRec.FromPackingCode = inputObj.Code; + //packRec.FromTopPackingCode = inventoryLabelObj.Code; + packRec.FromStdPackQty = inputObj.StdPackQty; + packRec.FromUom = inputObj.Uom; + packRec.FromQty = inputObj.Qty; + packRec.ToPackingCode = inputObj.Code; + //packRec.ToTopPackingCode = inventoryLabelObj.Code; + packRec.ToStdPackQty = inputObj.StdPackQty; + packRec.ToUom = inputObj.Uom; + packRec.ToQty = inputObj.Qty; + packRec.ItemCode = inputObj.ItemCode; + packRec.ItemName = inputObj.ItemName; + packRec.ItemDesc1 = inputObj.ItemDesc1; + packRec.ItemDesc2 = inputObj.ItemDesc2; + packRec.FromLot = inputObj.Lot; + packRec.ToLot = inputObj.Lot; + packRec.PurchaseInfo_PoNumber = inputObj.PoNumber; // 采购订单 + packRec.PurchaseInfo_AsnNumber = inputObj.AsnNumber; //供应商发货单 + packRec.ArrivalNoticNumber = null; //到货通知 + packRec.TaskOrderNumber = null; //任务单 + packRec.ReceiptRecNumber = null; //收货记录单 + packRec.PutOnShelfNumber = null; //上架单 + recLst.Add(packRec); + bool bo = await _splitPackingRecAppService.BatchInsertAsync(recLst).ConfigureAwait(false); + if (bo == false) + { + throw new UserFriendlyException("调用插入拆箱记录表方法时返回假!"); + } + } + #endregion + + var entitys = ObjectMapper.Map, List>(inputs); + await _repository.InsertManyAsync(entitys).ConfigureAwait(false); + return ObjectMapper.Map, List>(entitys); + } + + [HttpPost("generate-and-create")] [UnitOfWork] public virtual async Task GenerateAndCreateAsync(InventoryLabelWithoutCodeCreateInput input) diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/SfsCrudWithDetailsAppServiceBase.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/SfsCrudWithDetailsAppServiceBase.cs index 64a9ac7db..45001dae6 100644 --- a/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/SfsCrudWithDetailsAppServiceBase.cs +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Application/SfsCrudWithDetailsAppServiceBase.cs @@ -399,6 +399,7 @@ public abstract class SfsCrudWithDetailsAppServiceBase(); await Cache.SetItemAsync(dto.Id.ToString(), dto, SfsCacheConst.SeveralMinutes).ConfigureAwait(false); return dto; diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Basedata/EnumBusinessType.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Basedata/EnumBusinessType.cs new file mode 100644 index 000000000..6c6f57e10 --- /dev/null +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Basedata/EnumBusinessType.cs @@ -0,0 +1,28 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using System.Xml.Linq; + +namespace Win_in.Sfs.Shared.Domain.Shared; +public enum EnumBusinessType +{ + /// + /// 空枚举 + /// + [Display(Name = "空")] None = 0, + /// + /// 空枚举 + /// + [Display(Name = "注塑")] InjectionMolding = 1, + /// + /// 空枚举 + /// + [Display(Name = "喷涂")] Spray = 2, + /// + /// 空枚举 + /// + [Display(Name = "装配")] Assemble = 3, +} diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Basedata/EnumEquipmentModel.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Basedata/EnumEquipmentModel.cs new file mode 100644 index 000000000..65dd23a40 --- /dev/null +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Basedata/EnumEquipmentModel.cs @@ -0,0 +1,37 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Shared.Domain.Shared.Enums.Basedata; +public enum EnumEquipmentType +{ + [Display(Name = "小")] + Small =0, + [Display(Name = "大")] + Large =1, + [Display(Name = "超大")] + Oversized =2 +} + +public enum EnumEquipmentModel +{ + + /// + /// 内部 + /// + [Display(Name = "内部")] + Internal = 0, + + /// + /// 外部 + /// + [Display(Name = "外部")] + External = 1, + + + + +} diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Job/EnumJobType.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Job/EnumJobType.cs index e074a20cc..d526b507c 100644 --- a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Job/EnumJobType.cs +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Job/EnumJobType.cs @@ -91,5 +91,11 @@ public enum EnumJobType /// 转移 /// [Display(Name = "转移")] - Transfer = 14, + Transfer = 15, + + /// + /// 器具转移 + /// + [Display(Name = "转移")] + ContainerTransferJob = 16, } diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/EnumRecommendType.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/EnumRecommendType.cs new file mode 100644 index 000000000..4b64c050b --- /dev/null +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/EnumRecommendType.cs @@ -0,0 +1,32 @@ +using System.ComponentModel.DataAnnotations; + +namespace Win_in.Sfs.Shared.Domain.Shared; + +/// +/// 推荐类型 +/// +public enum EnumRecommendType +{ + /// + /// 空枚举 + /// + None = 0, + + /// + /// 原料 + /// + [Display(Name = "原料")] + W = 1, + + /// + /// 器具 + /// + [Display(Name = "器具")] + Q = 2, + + /// + /// kitting区 + /// + [Display(Name = "Kitting区")] + K = 3 +} diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/Statuses/EnumEquipmentRecordType.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/Statuses/EnumEquipmentRecordType.cs new file mode 100644 index 000000000..4557aca04 --- /dev/null +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/Statuses/EnumEquipmentRecordType.cs @@ -0,0 +1,13 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Shared.Domain.Shared.Enums.Store.Statuses; +public enum EnumEquipmentRecordType +{ + Bind=0, + UnBind=1 + +} diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/Types/EnumContainerSpecificationsType.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/Types/EnumContainerSpecificationsType.cs new file mode 100644 index 000000000..46e4df8ac --- /dev/null +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/Types/EnumContainerSpecificationsType.cs @@ -0,0 +1,27 @@ +using System.ComponentModel.DataAnnotations; + +namespace Win_in.Sfs.Shared.Domain.Shared; + +/// +/// 器具规格 +/// +public enum EnumContainerSpecificationsType +{ + /// + /// 空枚举 + /// + [Display(Name = "空枚举")] + None = 0, + + /// + /// 大器具 + /// + [Display(Name = "大器具")] + BigContainer = 1, + + /// + /// 小器具 + /// + [Display(Name = "小器具")] + SmallContainer = 2, +} diff --git a/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/Types/EnumContainerType.cs b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/Types/EnumContainerType.cs new file mode 100644 index 000000000..6d4644dbd --- /dev/null +++ b/be/Modules/Shared/src/Win_in.Sfs.Shared.Domain.Shared/Enums/Store/Types/EnumContainerType.cs @@ -0,0 +1,27 @@ +using System.ComponentModel.DataAnnotations; + +namespace Win_in.Sfs.Shared.Domain.Shared; + +/// +/// 器具类型 +/// +public enum EnumContainerType +{ + /// + /// 空枚举 + /// + [Display(Name = "空枚举")] + None = 0, + + /// + /// 内物流 + /// + [Display(Name = "内物流")] + InLogistics = 1, + + /// + /// 外物流 + /// + [Display(Name = "外物流")] + OutLogistics = 2, +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/DTOs/EquipmentRecordDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/DTOs/EquipmentRecordDTO.cs new file mode 100644 index 000000000..bba6be6c3 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/DTOs/EquipmentRecordDTO.cs @@ -0,0 +1,53 @@ +using System; +using System.ComponentModel; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; +[Display(Name = "器具操作")] +public class EquipmentRecordDTO : SfsBasicDTOBase +{ + /// + /// 器具编码 + /// + [Display(Name = "器具编码")] + public string EqptCode { get; set; } + /// + /// 条码编号 + /// + [Display(Name = "条码编号")] + public string BarCode { get; set; } + /// + /// 零件号 + /// + [Display(Name = "零件号")] + public string PartCode { get; set; } + /// + /// 批次 + /// + [Display(Name = "批次")] + public string Batch { get; set; } + /// + /// 库位 + /// + [Display(Name = "库位")] + public string LocCode { get; set; } + /// + /// 数量 + /// + [Display(Name = "数量")] + public decimal Qty { get; set; } + /// + /// 状态 + /// + [Display(Name = "状态")] + public int State { get; set; } + /// + /// 记录类型 + /// + [Display(Name = "记录类型")] + public int Type { get; set; } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/EquipmentRecordPermissions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/EquipmentRecordPermissions.cs new file mode 100644 index 000000000..5a8acb04a --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/EquipmentRecordPermissions.cs @@ -0,0 +1,22 @@ +using Volo.Abp.Authorization.Permissions; +using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Equipments; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public static class EquipmentRecordPermissions +{ + + public const string Default = StorePermissions.GroupName + "." + nameof(PurchaseOrder); + public const string Create = Default + "." + StorePermissions.CreateStr; + public const string Update = Default + "." + StorePermissions.UpdateStr; + public const string Delete = Default + "." + StorePermissions.DeleteStr; + + public static void AddEquipmentRecordPermission(this PermissionGroupDefinition permissionGroup) + { + var purchaseOrderPermission = permissionGroup.AddPermission(Default, StorePermissionDefinitionProvider.L(nameof(EquipmentRecord))); + purchaseOrderPermission.AddChild(Create, StorePermissionDefinitionProvider.L(StorePermissions.CreateStr)); + purchaseOrderPermission.AddChild(Update, StorePermissionDefinitionProvider.L(StorePermissions.UpdateStr)); + purchaseOrderPermission.AddChild(Delete, StorePermissionDefinitionProvider.L(StorePermissions.DeleteStr)); + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/IEquipmentRecordAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/IEquipmentRecordAppService.cs new file mode 100644 index 000000000..e9f750f2d --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/IEquipmentRecordAppService.cs @@ -0,0 +1,23 @@ +using System; +using System.Collections.Generic; +using System.Threading.Tasks; +using Win_in.Sfs.Basedata.Equipments.DTOs; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Wms.Store.Equipments; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public interface IEquipmentRecordAppService + : + ISfsStoreMasterAppServiceBase, + ISfsCheckStatusAppService + , ISfsUpsertAppService +{ + + + Task> Bind(List p_ls); + Task> UnBind(List p_ls); + + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/Inputs/EquipmentRecordEditInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/Inputs/EquipmentRecordEditInput.cs new file mode 100644 index 000000000..de51993b0 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/Inputs/EquipmentRecordEditInput.cs @@ -0,0 +1,57 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; +[Display(Name = "器具操作")] +public class EquipmentRecordEditInput + : SfsStoreCreateOrUpdateInputBase +{ + /// + /// 器具编码 + /// + [Display(Name = "器具编码")] + public string EqptCode { get; set; } + /// + /// 条码编号 + /// + [Display(Name = "条码编号")] + public string BarCode { get; set; } + /// + /// 零件号 + /// + [Display(Name = "零件号")] + public string PartCode { get; set; } + /// + /// 批次 + /// + [Display(Name = "批次")] + public string Batch { get; set; } + /// + /// 库位 + /// + [Display(Name = "库位")] + public string LocCode { get; set; } + /// + /// 数量 + /// + [Display(Name = "数量")] + public decimal Qty { get; set; } + /// + /// 状态 + /// + [Display(Name = "状态")] + public int State { get; set; } + /// + /// 记录类型 + /// + [Display(Name = "记录类型")] + public int Type { get; set; } + + +} + + diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/Inputs/EquipmentRecordImportInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/Inputs/EquipmentRecordImportInput.cs new file mode 100644 index 000000000..82901aeda --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Equipments/Inputs/EquipmentRecordImportInput.cs @@ -0,0 +1,53 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Application.Contracts.ExportAndImport; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +[Display(Name = "器具操作")] +public class EquipmentRecordImportInput : SfsStoreImportInputBase +{ + /// + /// 器具编码 + /// + [Display(Name = "器具编码")] + public string EqptCode { get; set; } + /// + /// 条码编号 + /// + [Display(Name = "条码编号")] + public string BarCode { get; set; } + /// + /// 零件号 + /// + [Display(Name = "零件号")] + public string PartCode { get; set; } + /// + /// 批次 + /// + [Display(Name = "批次")] + public string Batch { get; set; } + /// + /// 库位 + /// + [Display(Name = "库位")] + public string LocCode { get; set; } + /// + /// 数量 + /// + [Display(Name = "数量")] + public decimal Qty { get; set; } + /// + /// 状态 + /// + [Display(Name = "状态")] + public int State { get; set; } + /// + /// 记录类型 + /// + [Display(Name = "记录类型")] + public int Type { get; set; } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/ContainerJobPermissions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/ContainerJobPermissions.cs new file mode 100644 index 000000000..56f20cda1 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/ContainerJobPermissions.cs @@ -0,0 +1,27 @@ +using Volo.Abp.Authorization.Permissions; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public static class ContainerJobPermissions +{ + + public const string Default = StorePermissions.GroupName + "." + nameof(ContainerJob); + public const string Create = Default + "." + StorePermissions.CreateStr; + public const string Update = Default + "." + StorePermissions.UpdateStr; + public const string Delete = Default + "." + StorePermissions.DeleteStr; + + //自动发料任务 + public const string AutoContainerJob = StorePermissions.GroupName + "." + nameof(AutoContainerJob); + + public static void AddContainerJobPermission(this PermissionGroupDefinition permissionGroup) + { + var ContainerJobPermission = permissionGroup.AddPermission(Default, StorePermissionDefinitionProvider.L(nameof(ContainerJob))); + ContainerJobPermission.AddChild(Create, StorePermissionDefinitionProvider.L(StorePermissions.CreateStr)); + ContainerJobPermission.AddChild(Update, StorePermissionDefinitionProvider.L(StorePermissions.UpdateStr)); + ContainerJobPermission.AddChild(Delete, StorePermissionDefinitionProvider.L(StorePermissions.DeleteStr)); + + permissionGroup.AddPermission(AutoContainerJob, StorePermissionDefinitionProvider.L(nameof(AutoContainerJob))); + + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/DTOs/ContainerJobDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/DTOs/ContainerJobDTO.cs new file mode 100644 index 000000000..2204a2b0c --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/DTOs/ContainerJobDTO.cs @@ -0,0 +1,49 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +/// +/// 器具呼叫任务 +/// +[Display(Name = "器具呼叫任务")] +public class ContainerJobDTO : SfsJobDTOBase +{ + + /// + /// 器具呼叫号码 + /// + [Display(Name = "器具呼叫号码")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ContainerRequestNumber { get; set; } + + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string RequestLocationCode { get; set; } + + /// + /// 器具类型 + /// + [Display(Name = "器具类型")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ContainerType { get; set; } + + /// + /// 器具规格 + /// + [Display(Name = "器具规格")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string SpecificationsType { get; set; } + + /// + /// 器具规格名称 + /// + [Display(Name = "器具规格名称")] + public string SpecificationsTypeName { get; set; } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/DTOs/ContainerJobDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/DTOs/ContainerJobDetailDTO.cs new file mode 100644 index 000000000..af036265e --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/DTOs/ContainerJobDetailDTO.cs @@ -0,0 +1,22 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerJobDetailDTO : SfsJobRecommendFromDetailDTOBase +{ + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + public string ToLocationCode { get; set; } + + /// + /// 来源库位代码 + /// + [Display(Name = "来源库位代码")] + public string FromLocationCode { get; set; } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/IContainerJobAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/IContainerJobAppService.cs new file mode 100644 index 000000000..9bfdc589f --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/IContainerJobAppService.cs @@ -0,0 +1,16 @@ +using System.Collections.Generic; +using System.Threading; +using System.Threading.Tasks; +using Volo.Abp.Application.Dtos; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public interface IContainerJobAppService + : ISfsJobAppServiceBase +{ + + + Task> GetByRequestNumberAsync(string requestNumber); + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/Inputs/ContainerJobCheckInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/Inputs/ContainerJobCheckInput.cs new file mode 100644 index 000000000..29c79d6c2 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/Inputs/ContainerJobCheckInput.cs @@ -0,0 +1,6 @@ +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerJobCheckInput : SfsJobCheckInputBase +{ + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/Inputs/ContainerJobDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/Inputs/ContainerJobDetailInput.cs new file mode 100644 index 000000000..8622fac74 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/Inputs/ContainerJobDetailInput.cs @@ -0,0 +1,27 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerJobDetailInput : SfsJobRecommendFromDetailInputBase +{ + + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ToLocationCode { get; set; } + + /// + /// 来源库位代码 + /// + [Display(Name = "来源库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string FromLocationCode { get; set; } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/Inputs/ContainerJobEditInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/Inputs/ContainerJobEditInput.cs new file mode 100644 index 000000000..f688c14c4 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ContainerJobs/Inputs/ContainerJobEditInput.cs @@ -0,0 +1,70 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerJobEditInput : SfsJobCreateUpdateInputBase, ISfsJobCreateInput +{ + #region Create + + /// + /// 器具呼叫号码 + /// + [Display(Name = "器具呼叫号码")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + [Required(ErrorMessage = "{0}是必填项")] + public string ContainerRequestNumber { get; set; } + + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string RequestLocationCode { get; set; } + + /// + /// 器具类型 + /// + [Display(Name = "器具类型")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ContainerType { get; set; } + + /// + /// 器具规格 + /// + [Display(Name = "器具规格")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string SpecificationsType { get; set; } + + /// + /// 上游任务编号 + /// + [Display(Name = "上游任务编号")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string UpStreamJobNumber { get; set; } + + /// + /// 任务类型 + /// + [Display(Name = "任务类型")] + [Required(ErrorMessage = "{0}是必填项")] + public EnumJobType JobType { get; set; } + + /// + /// 是否自动完成 + /// + [Display(Name = "是否自动完成")] + [Required(ErrorMessage = "{0}是必填项")] + public bool IsAutoComplete { get; set; } + + /// + /// 任务明细 + /// + [Display(Name = "任务明细")] + [Required(ErrorMessage = "{0}是必填项")] + public List Details { get; set; } = new(); + #endregion +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/InspectJobs/IInspectJobAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/InspectJobs/IInspectJobAppService.cs index 2bc8a2f43..65fe5830a 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/InspectJobs/IInspectJobAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/InspectJobs/IInspectJobAppService.cs @@ -43,4 +43,11 @@ public interface IInspectJobAppService Task CancelByInspectRequestAsync(string inspectRequestNumber); Task GetInspectNoteDetailByPackingCodeAsync(string packingCode); + + /// + /// 保存拆箱时涉及的明细修改 + /// + /// + Task SaveDetail_SplitPackingAsync(SplitPacking_UpdateJobDetailInput input); + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/IssueJobs/IIssueJobAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/IssueJobs/IIssueJobAppService.cs index 1b9ad5f7d..306f0df4e 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/IssueJobs/IIssueJobAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/IssueJobs/IIssueJobAppService.cs @@ -16,4 +16,11 @@ public interface IIssueJobAppService bool includeDetails = false, CancellationToken cancellationToken = default); Task> GetByRequestNumberAsync(string requestNumber); + + /// + /// 保存拆箱时涉及的明细修改 + /// + /// + Task SaveDetail_SplitPackingAsync(SplitPacking_UpdateJobDetailInput input); + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/IssueJobs/Inputs/IssueJobDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/IssueJobs/Inputs/IssueJobDetailInput.cs index e21c6f385..b059524c9 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/IssueJobs/Inputs/IssueJobDetailInput.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/IssueJobs/Inputs/IssueJobDetailInput.cs @@ -121,4 +121,14 @@ public class IssueJobDetailInput : SfsJobRecommendFromDetailInputBase, IHasToLoc /// [Display(Name = "每次配送数量")] public decimal DeliveryQty { get; set; } + + /// + /// 位置码 + /// + public string PositionCode { get; set; } + + /// + /// 推荐类型 + /// + public EnumRecommendType RecommendType { get; set; } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/DTOs/ProductRecycleJobDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/DTOs/ProductRecycleJobDTO.cs new file mode 100644 index 000000000..12e3f745f --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/DTOs/ProductRecycleJobDTO.cs @@ -0,0 +1,23 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +[Display(Name = "客户退拆任务")] +public class ProductRecycleJobDTO : SfsJobDTOBase +{ + + /// + /// 车间 + /// + [Display(Name = "车间")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string Workshop { get; set; } + + /// + /// 班次 + /// + [Display(Name = "班次")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string Shift { get; set; } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/DTOs/ProductRecycleJobDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/DTOs/ProductRecycleJobDetailDTO.cs new file mode 100644 index 000000000..32f7be931 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/DTOs/ProductRecycleJobDetailDTO.cs @@ -0,0 +1,90 @@ +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Volo.Abp.Data; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ProductRecycleJobDetailDTO : SfsJobRecommendToDetailDTOBase +{ + /// + /// Bom版本 + /// + public string BomVersion { get; set; } + + /// + /// 库位代码 + /// + public string LocationCode { get; set; } + + /// + /// 库区 + /// + public string LocationArea { get; set; } + + /// + /// 库位组 + /// + public string LocationGroup { get; set; } + + /// + /// ERP库位代码 + /// + public string LocationErpCode { get; set; } + + /// + /// 原料库位代码 + /// + public string RawLocationCode { get; set; } + + /// + /// 原料库区 + /// + public string RawLocationArea { get; set; } + + /// + /// 原料库位组 + /// + public string RawLocationGroup { get; set; } + + /// + /// 原料ERP库位 + /// + public string RawLocationErpCode { get; set; } + + /// + /// 原料仓库 + /// + public string RawWarehouseCode { get; set; } + + /// + /// 计量单位 + /// + [Display(Name = "计量单位")] + [MaxLength(SfsPropertyConst.CodeLength)] + public string Uom { get; set; } + + /// + /// 数量 + /// + [Display(Name = "数量")] + [Column(TypeName = "decimal(18,6)")] + public decimal Qty { get; set; } + + /// + /// 扩展属性 + /// + public ExtraPropertyDictionary ExtraProperties { get; } = new ExtraPropertyDictionary(); + + /// + /// 库存状态 + /// + public EnumInventoryStatus Status { get; set; } + + /// + /// 仓库代码 + /// + public string WarehouseCode { get; set; } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/IProductRecycleJobAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/IProductRecycleJobAppService.cs new file mode 100644 index 000000000..c68fa097a --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/IProductRecycleJobAppService.cs @@ -0,0 +1,10 @@ +using System.Threading.Tasks; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public interface IProductRecycleJobAppService + : ISfsJobAppServiceBase + +{ + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobCheckInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobCheckInput.cs new file mode 100644 index 000000000..4dc7816e5 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobCheckInput.cs @@ -0,0 +1,6 @@ +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ProductRecycleJobCheckInput : SfsJobCheckInputBase +{ + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobDetailInput.cs new file mode 100644 index 000000000..696e2b713 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobDetailInput.cs @@ -0,0 +1,90 @@ +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Volo.Abp.Data; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ProductRecycleJobDetailInput : SfsJobRecommendToDetailInputBase +{ + /// + /// Bom版本 + /// + public string BomVersion { get; set; } + + /// + /// 库位代码 + /// + public string LocationCode { get; set; } + + /// + /// 库区 + /// + public string LocationArea { get; set; } + + /// + /// 库位组 + /// + public string LocationGroup { get; set; } + + /// + /// ERP库位代码 + /// + public string LocationErpCode { get; set; } + + /// + /// 原料库位代码 + /// + public string RawLocationCode { get; set; } + + /// + /// 原料库区 + /// + public string RawLocationArea { get; set; } + + /// + /// 原料库位组 + /// + public string RawLocationGroup { get; set; } + + /// + /// 原料ERP库位 + /// + public string RawLocationErpCode { get; set; } + + /// + /// 原料仓库 + /// + public string RawWarehouseCode { get; set; } + + /// + /// 计量单位 + /// + [Display(Name = "计量单位")] + [MaxLength(SfsPropertyConst.CodeLength)] + public string Uom { get; set; } + + /// + /// 数量 + /// + [Display(Name = "数量")] + [Column(TypeName = "decimal(18,6)")] + public decimal Qty { get; set; } + + /// + /// 扩展属性 + /// + public ExtraPropertyDictionary ExtraProperties { get; } = new ExtraPropertyDictionary(); + + /// + /// 库存状态 + /// + public EnumInventoryStatus Status { get; set; } + + /// + /// 仓库代码 + /// + public string WarehouseCode { get; set; } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobDetailSaveInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobDetailSaveInput.cs new file mode 100644 index 000000000..fa5580803 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobDetailSaveInput.cs @@ -0,0 +1,43 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.FileStorage.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +/// +/// 客户退拆 保存模型 +/// +public class ProductRecycleJobDetailSaveInput +{ + /// + /// Id + /// + [Display(Name = "Id")] + public Guid Id { get; set; } + /// + /// 详情ID + /// + [Display(Name = "详情ID")] + public Guid DetailId { get; set; } + + /// + /// 不合格原因 + /// + [Display(Name = "不合格原因")] + public string FailedReason { get; set; } + + /// + /// 质量缺陷 + /// + [Display(Name = "质量缺陷")] + public string MassDefect { get; set; } + + + /// + /// 图片字节流 + /// + [Display(Name = "图片字节流")] + public List FilesList { get; set; } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobEditInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobEditInput.cs new file mode 100644 index 000000000..759bd3f2b --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/Inputs/ProductRecycleJobEditInput.cs @@ -0,0 +1,55 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ProductRecycleJobEditInput : SfsJobCreateUpdateInputBase, ISfsJobCreateInput +{ + #region Create + + /// + /// 车间 + /// + [Display(Name = "车间")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string Workshop { get; set; } + + /// + /// 上游任务编号 + /// + [Display(Name = "上游任务编号")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string UpStreamJobNumber { get; set; } + + /// + /// 任务类型 + /// + [Display(Name = "任务类型")] + [Required(ErrorMessage = "{0}是必填项")] + public EnumJobType JobType { get; set; } + + /// + /// 是否自动完成 + /// + [Display(Name = "是否自动完成")] + [Required(ErrorMessage = "{0}是必填项")] + public bool IsAutoComplete { get; set; } + + /// + /// 过期时间 + /// + [Display(Name = "过期时间")] + [Required(ErrorMessage = "{0}是必填项")] + public DateTime ExpiredTime { get; set; } + + /// + /// 任务明细 + /// + [Display(Name = "任务明细")] + [Required(ErrorMessage = "{0}是必填项")] + public List Details { get; set; } + #endregion +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/ProductRecycleJobPermissions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/ProductRecycleJobPermissions.cs new file mode 100644 index 000000000..545314ba2 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/ProductRecycleJobs/ProductRecycleJobPermissions.cs @@ -0,0 +1,20 @@ +using Volo.Abp.Authorization.Permissions; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public static class ProductRecycleJobPermissions +{ + public const string Default = StorePermissions.GroupName + "." + nameof(ProductRecycleJob); + public const string Create = Default + "." + StorePermissions.CreateStr; + public const string Update = Default + "." + StorePermissions.UpdateStr; + public const string Delete = Default + "." + StorePermissions.DeleteStr; + + public static void AddProductRecycleJobPermission(this PermissionGroupDefinition permissionGroup) + { + var productRecycleJobPermission = permissionGroup.AddPermission(Default, StorePermissionDefinitionProvider.L(nameof(ProductRecycleJob))); + productRecycleJobPermission.AddChild(Create, StorePermissionDefinitionProvider.L(StorePermissions.CreateStr)); + productRecycleJobPermission.AddChild(Update, StorePermissionDefinitionProvider.L(StorePermissions.UpdateStr)); + productRecycleJobPermission.AddChild(Delete, StorePermissionDefinitionProvider.L(StorePermissions.DeleteStr)); + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/PurchaseReceiptJobs/IPurchaseReceiptJobAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/PurchaseReceiptJobs/IPurchaseReceiptJobAppService.cs index 027134838..921906b69 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/PurchaseReceiptJobs/IPurchaseReceiptJobAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Jobs/PurchaseReceiptJobs/IPurchaseReceiptJobAppService.cs @@ -46,4 +46,19 @@ public interface IPurchaseReceiptJobAppService /// /// Task> GetListBySupplierCodeOnTodayAsync(string supplierCode); + + /// + /// 根据number取列表 + /// + /// + /// + Task> GetListByNumberAsync(string number); + + /// + /// 保存拆箱时涉及的明细修改 + /// + /// + Task SaveDetail_SplitPackingAsync(SplitPacking_UpdateJobDetailInput input); + + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/ContainerNotePermissions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/ContainerNotePermissions.cs new file mode 100644 index 000000000..6b08a7689 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/ContainerNotePermissions.cs @@ -0,0 +1,27 @@ +using Volo.Abp.Authorization.Permissions; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public static class ContainerNotePermissions +{ + public const string Default = StorePermissions.GroupName + "." + nameof(ContainerNote); + public const string Create = Default + "." + StorePermissions.CreateStr; + public const string Update = Default + "." + StorePermissions.UpdateStr; + public const string Delete = Default + "." + StorePermissions.DeleteStr; + + + //器具呼叫记录 + public const string ContainerNote = StorePermissions.GroupName + "." + nameof(ContainerNote); + + public static void AddContainerNotePermission(this PermissionGroupDefinition permissionGroup) + { + var ContainerNotePermission = permissionGroup.AddPermission(Default, StorePermissionDefinitionProvider.L(nameof(ContainerNote))); + ContainerNotePermission.AddChild(Create, StorePermissionDefinitionProvider.L(StorePermissions.CreateStr)); + ContainerNotePermission.AddChild(Update, StorePermissionDefinitionProvider.L(StorePermissions.UpdateStr)); + ContainerNotePermission.AddChild(Delete, StorePermissionDefinitionProvider.L(StorePermissions.DeleteStr)); + + permissionGroup.AddPermission(ContainerNote, StorePermissionDefinitionProvider.L(nameof(ContainerNote))); + + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/DTOs/ContainerNoteDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/DTOs/ContainerNoteDTO.cs new file mode 100644 index 000000000..f899f7793 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/DTOs/ContainerNoteDTO.cs @@ -0,0 +1,56 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerNoteDTO : SfsStoreDTOBase, IHasJobNumber +{ + + /// + /// 任务ID + /// + [Display(Name = "任务ID")] + public string JobNumber { get; set; } + + /// + /// 器具申请号码 + /// + [Display(Name = "器具申请号码")] + public string ContainerRequestNumber { get; set; } + + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string RequestLocationCode { get; set; } + + /// + /// 器具类型 + /// + [Display(Name = "器具类型")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ContainerType { get; set; } + + /// + /// 器具规格 + /// + [Display(Name = "器具规格")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string SpecificationsType { get; set; } + + /// + /// 已确认 + /// + [Display(Name = "已确认")] + public bool Confirmed { get; set; } + + /// + /// 确认时间 + /// + [Display(Name = "确认时间")] + public DateTime? ConfirmTime { get; set; } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/DTOs/ContainerNoteDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/DTOs/ContainerNoteDetailDTO.cs new file mode 100644 index 000000000..8446e5262 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/DTOs/ContainerNoteDetailDTO.cs @@ -0,0 +1,22 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerNoteDetailDTO : SfsStoreRecommendFromDetailWithFromToDTOBase +{ + + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + public string ToLocationCode { get; set; } + + /// + /// 来源库位代码 + /// + [Display(Name = "来源库位代码")] + public string FromLocationCode { get; set; } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/IContainerNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/IContainerNoteAppService.cs new file mode 100644 index 000000000..dae04b4c4 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/IContainerNoteAppService.cs @@ -0,0 +1,18 @@ +using System; +using System.Collections.Generic; +using System.Threading; +using System.Threading.Tasks; +using Volo.Abp.Application.Dtos; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public interface IContainerNoteAppService : ISfsStoreMasterReadOnlyAppServiceBase +{ + Task CreateAsync(ContainerNoteEditInput input); + + Task ConfirmAsync(Guid id); + + Task ConfirmAsync(string number); + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/Inputs/ContainerNoteDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/Inputs/ContainerNoteDetailInput.cs new file mode 100644 index 000000000..d47dbdcb4 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/Inputs/ContainerNoteDetailInput.cs @@ -0,0 +1,23 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerNoteDetailInput : SfsStoreRecommendFromDetailWithFromToInputBase +{ + + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + public string ToLocationCode { get; set; } + + /// + /// 来源库位代码 + /// + [Display(Name = "来源库位代码")] + public string FromLocationCode { get; set; } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/Inputs/ContainerNoteEditInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/Inputs/ContainerNoteEditInput.cs new file mode 100644 index 000000000..55420ab2a --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/Inputs/ContainerNoteEditInput.cs @@ -0,0 +1,69 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerNoteEditInput : SfsStoreCreateOrUpdateInputBase +{ + #region Base + /// + /// 已确认 + /// + [Display(Name = "已确认")] + public bool Confirmed { get; set; } + + /// + /// 确认时间 + /// + [Display(Name = "确认时间")] + public DateTime? ConfirmTime { get; set; } + #endregion + + #region Create + + /// + /// 任务ID + /// + [Display(Name = "任务ID")] + public string JobNumber { get; set; } + + /// + /// 器具申请号码 + /// + [Display(Name = "器具申请号码")] + [Required(ErrorMessage = "{0}是必填项")] + public string ContainerRequestNumber { get; set; } + + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string RequestLocationCode { get; set; } + + /// + /// 器具类型 + /// + [Display(Name = "器具类型")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ContainerType { get; set; } + + /// + /// 器具规格 + /// + [Display(Name = "器具规格")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string SpecificationsType { get; set; } + + /// + /// 明细列表 + /// + [Display(Name = "明细列表")] + public List Details { get; set; } + + + #endregion +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/Inputs/ContainerNoteImportInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/Inputs/ContainerNoteImportInput.cs new file mode 100644 index 000000000..57e02c619 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ContainerNotes/Inputs/ContainerNoteImportInput.cs @@ -0,0 +1,42 @@ +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerNoteImportInput : SfsStoreImportInputBase, IHasJobNumber +{ + /// + /// 任务ID + /// + [Display(Name = "任务ID")] + public string JobNumber { get; set; } + + /// + /// 器具申请号码 + /// + [Display(Name = "器具申请号码")] + [Required(ErrorMessage = "{0}是必填项")] + public string ContainerRequestNumber { get; set; } + + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string RequestLocationCode { get; set; } + + /// + /// 器具类型 + /// + [Display(Name = "器具类型")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string ContainerType { get; set; } + + /// + /// 器具规格 + /// + [Display(Name = "器具规格")] + [StringLength(SfsEfCorePropertyConst.NameLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string SpecificationsType { get; set; } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/IssueNotes/Inputs/IssueNoteDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/IssueNotes/Inputs/IssueNoteDetailInput.cs index b85bdb0a2..0d8769392 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/IssueNotes/Inputs/IssueNoteDetailInput.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/IssueNotes/Inputs/IssueNoteDetailInput.cs @@ -1,6 +1,7 @@ using System; using System.ComponentModel.DataAnnotations; using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; namespace Win_in.Sfs.Wms.Store.Application.Contracts; @@ -39,4 +40,14 @@ public class IssueNoteDetailInput : SfsStoreRecommendFromDetailWithFromToInputBa [Display(Name = "在途库库位")] public string OnTheWayLocationCode { get; set; } + /// + /// 位置码 + /// + public string PositionCode { get; set; } + + /// + /// 推荐类型 + /// + public EnumRecommendType RecommendType { get; set; } + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ItemTransformNotes/Inputs/ItemTransformNoteEditInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ItemTransformNotes/Inputs/ItemTransformNoteEditInput.cs index f510825a1..89b78e113 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ItemTransformNotes/Inputs/ItemTransformNoteEditInput.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ItemTransformNotes/Inputs/ItemTransformNoteEditInput.cs @@ -33,5 +33,10 @@ public class ItemTransformNoteEditInput : SfsStoreCreateOrUpdateInputBase /// [Display(Name = "明细列表")] public List Details { get; set; } = new List(); + /// + /// 混拌料入库数据 + /// + + public List RecDetails { get; set; } = new List(); #endregion } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ProductRecycleNotes/DTOs/ProductRecycleNoteDetailExtendDto.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ProductRecycleNotes/DTOs/ProductRecycleNoteDetailExtendDto.cs new file mode 100644 index 000000000..2d249d85e --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/ProductRecycleNotes/DTOs/ProductRecycleNoteDetailExtendDto.cs @@ -0,0 +1,27 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Wms.Store.Notes.ProductRecycleNotes.DTOs; +public class ProductRecycleNoteDetailExtendDto +{ + + [Display(Name ="报废类型")] + public string Type { get; set; } + [Display(Name = "物料代码")] + public string ItemCode { get; set; } + [Display(Name = "报废库位")] + + public string LocCode { get; set; } + [Display(Name = "数量")] + public Decimal Qty { get; set; } + + [Display(Name = "报废原因")] + public string Reason { get; set; } + + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PurchaseReceiptNotes/DTOs/PurchaseReceiptNoteDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PurchaseReceiptNotes/DTOs/PurchaseReceiptNoteDetailDTO.cs index f99cd6c5b..a64246980 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PurchaseReceiptNotes/DTOs/PurchaseReceiptNoteDetailDTO.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PurchaseReceiptNotes/DTOs/PurchaseReceiptNoteDetailDTO.cs @@ -57,3 +57,16 @@ public class PurchaseReceiptNoteDetailDTO : SfsStoreRecommendToDetailWithLotPack public decimal SupplierPackQty { get; set; } } + +public class PurchaseReceiptNoteDetail_ExtDTO : PurchaseReceiptNoteDetailDTO +{ + /// + /// 拆箱的源箱码 + /// + public string FromPackingCode { get; set; } + + /// + /// 拆箱的目标箱码 + /// + public string ToPackingCode { get; set; } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PurchaseReceiptNotes/IPurchaseReceiptNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PurchaseReceiptNotes/IPurchaseReceiptNoteAppService.cs index bc3f32af9..55bc79939 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PurchaseReceiptNotes/IPurchaseReceiptNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PurchaseReceiptNotes/IPurchaseReceiptNoteAppService.cs @@ -32,7 +32,7 @@ public interface IPurchaseReceiptNoteAppService : /// 获取详情 不合格 /// /// - Task> GetDetailListByNoOkAsync(Guid id); + Task> GetDetailListByNoOkAsync(Guid id); /// /// 获取详情 未收货 diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PutawayNotes/IPutawayNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PutawayNotes/IPutawayNoteAppService.cs index 936a32a74..a3bcdad39 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PutawayNotes/IPutawayNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/PutawayNotes/IPutawayNoteAppService.cs @@ -1,3 +1,4 @@ +using System; using System.Collections.Generic; using System.Threading; using System.Threading.Tasks; @@ -52,4 +53,5 @@ public interface IPutawayNoteAppService : ISfsStoreMasterReadOnlyAppServiceBase< CancellationToken cancellationToken = default); Task> GetListByAsnNumbers(IEnumerable asnNumbers); + Task PrintUpdateRemark(Guid id); } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/RecycledMaterialReceiptNotes/IRecycledMaterialReceiptNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/RecycledMaterialReceiptNotes/IRecycledMaterialReceiptNoteAppService.cs index 3b42f839c..d62a3746e 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/RecycledMaterialReceiptNotes/IRecycledMaterialReceiptNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/RecycledMaterialReceiptNotes/IRecycledMaterialReceiptNoteAppService.cs @@ -6,4 +6,5 @@ public interface IRecycledMaterialReceiptNoteAppService : ISfsStoreMasterReadOnlyAppServiceBase { Task CreateAsync(RecycledMaterialReceiptNoteEditInput input); + Task NewCreateAsync(RecycledMaterialReceiptNoteEditInput input); } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/TransferNotes/ITransferNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/TransferNotes/ITransferNoteAppService.cs index fc797cf4f..aceb3662a 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/TransferNotes/ITransferNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/TransferNotes/ITransferNoteAppService.cs @@ -63,4 +63,28 @@ public interface ITransferNoteAppService : Task> GetSplitPackingTransferListAsync( SfsStoreRequestInputBase sfsRequestDTO, bool includeDetails = false, CancellationToken cancellationToken = default); + + /// + /// 采购收货拆箱,同时更新、插入PurchaseReceipt任务表、申请表 + /// + /// + /// + /// + Task SplitPacking_PurchaseReceiptAsync(TransferNoteEditInput transferNoteEditInput, SplitPacking_UpdateJobDetailInput updateJobDetailInput); + + /// + /// 质检拆箱,同时更新、插入Inspect任务表(不更新申请表) + /// + /// + /// + /// + Task SplitPacking_InspectAsync(TransferNoteEditInput transferNoteEditInput, SplitPacking_UpdateJobDetailInput updateJobDetailInput); + + /// + /// 发料拆箱,同时更新、插入Inspect任务表(没有找到申请表//??) + /// + /// + /// + /// + Task SplitPacking_IssueAsync(TransferNoteEditInput transferNoteEditInput, SplitPacking_UpdateJobDetailInput updateJobDetailInput); } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/TransferNotes/Inputs/SplitPacking_UpdateJobDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/TransferNotes/Inputs/SplitPacking_UpdateJobDetailInput.cs new file mode 100644 index 000000000..c7f3f321e --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Notes/TransferNotes/Inputs/SplitPacking_UpdateJobDetailInput.cs @@ -0,0 +1,42 @@ +using System.ComponentModel.DataAnnotations; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class SplitPacking_UpdateJobDetailInputBase +{ + /// + /// 主表number + /// + [Required(ErrorMessage = "{0}是必填项")] + public string Number { get; set; } +} + + /// + /// + /// +public class SplitPacking_UpdateJobDetailInput : SplitPacking_UpdateJobDetailInputBase +{ + /// + /// 子表from标签 + /// + [Required(ErrorMessage = "{0}是必填项")] + public string FromPackingCode { get; set; } + /// + /// from数量 + /// + [Required(ErrorMessage = "{0}是必填项")] + [Range(1, 99999, ErrorMessage = "{0}值范围在1至99999之间")] + public decimal FromQty { get; set; } + /// + /// 子表的to标签 + /// + [Required(ErrorMessage = "{0}是必填项")] + public string ToPackingCode { get; set; } + /// + /// to数量 + /// + [Required(ErrorMessage = "{0}是必填项")] + [Range(1, 99999, ErrorMessage = "{0}值范围在1至99999之间")] + public decimal ToQty { get; set; } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Orders/PurchaseOrders/IPurchaseOrderAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Orders/PurchaseOrders/IPurchaseOrderAppService.cs index 034ea1a1b..1a1394242 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Orders/PurchaseOrders/IPurchaseOrderAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Orders/PurchaseOrders/IPurchaseOrderAppService.cs @@ -39,4 +39,6 @@ public interface IPurchaseOrderAppService Task> CreateManyAsync(List inputs); Task> GetListBySupplierCodeAsync(string supplierCode, string itemCode); + Task> GetNoPoBillList(List poBillNo); + Task CreateOrUpdateAsync(PurchaseOrderEditInput input); } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Permissions/StorePermissionDefinitionProvider.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Permissions/StorePermissionDefinitionProvider.cs index 92bbc9d6d..b45ea84a6 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Permissions/StorePermissionDefinitionProvider.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Permissions/StorePermissionDefinitionProvider.cs @@ -26,7 +26,9 @@ public class StorePermissionDefinitionProvider : PermissionDefinitionProvider storeGroup.AddPurchaseReturnNotePermission(); storeGroup.AddPutawayNotePermission(); storeGroup.AddMaterialRequestPermission(); + storeGroup.AddContainerRequestPermission(); storeGroup.AddIssueNotePermission(); + storeGroup.AddContainerNotePermission(); storeGroup.AddUnplannedReceiptNotePermission(); storeGroup.AddUnplannedIssueNotePermission(); storeGroup.AddIsolationNotePermission(); @@ -88,9 +90,11 @@ public class StorePermissionDefinitionProvider : PermissionDefinitionProvider storeGroup.AddInspectJobPermission(); storeGroup.AddPutawayJobPermission(); storeGroup.AddIssueJobPermission(); + storeGroup.AddContainerJobPermission(); storeGroup.AddDeliverJobPermission(); storeGroup.AddPurchaseReturnJobPermission(); storeGroup.AddProductReceiveJobPermission(); + storeGroup.AddProductRecycleJobPermission(); storeGroup.AddCheckJobPermission(); storeGroup.AddCountJobPermission(); storeGroup.AddJisDeliverJobPermission(); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/ContainerRequestPermissions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/ContainerRequestPermissions.cs new file mode 100644 index 000000000..c5884c649 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/ContainerRequestPermissions.cs @@ -0,0 +1,27 @@ +using Volo.Abp.Authorization.Permissions; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public static class ContainerRequestPermissions +{ + + public const string Default = StorePermissions.GroupName + "." + nameof(ContainerRequest); + public const string Create = Default + "." + StorePermissions.CreateStr; + public const string Update = Default + "." + StorePermissions.UpdateStr; + public const string Delete = Default + "." + StorePermissions.DeleteStr; + + //器具呼叫申请 + public const string AutoContainerRequest = StorePermissions.GroupName + "." + nameof(AutoContainerRequest); + + public static void AddContainerRequestPermission(this PermissionGroupDefinition permissionGroup) + { + var ContainerRequestPermission = permissionGroup.AddPermission(Default, StorePermissionDefinitionProvider.L(nameof(ContainerRequest))); + ContainerRequestPermission.AddChild(Create, StorePermissionDefinitionProvider.L(StorePermissions.CreateStr)); + ContainerRequestPermission.AddChild(Update, StorePermissionDefinitionProvider.L(StorePermissions.UpdateStr)); + ContainerRequestPermission.AddChild(Delete, StorePermissionDefinitionProvider.L(StorePermissions.DeleteStr)); + + permissionGroup.AddPermission(AutoContainerRequest, StorePermissionDefinitionProvider.L(nameof(AutoContainerRequest))); + + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/DTOs/ContainerRequestDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/DTOs/ContainerRequestDTO.cs new file mode 100644 index 000000000..36668d33e --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/DTOs/ContainerRequestDTO.cs @@ -0,0 +1,30 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +/// +/// 器具呼叫DTO +/// +public class ContainerRequestDTO : SfsStoreRequestDTOBase +{ + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + public string RequestLocationCode { get; set; } + + /// + /// 器具类型 + /// + [Display(Name = "器具类型")] + public string ContainerType { get; set; } + + /// + /// 器具规格 + /// + [Display(Name = "器具规格")] + public string SpecificationsType { get; set; } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/DTOs/ContainerRequestDetailDTO.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/DTOs/ContainerRequestDetailDTO.cs new file mode 100644 index 000000000..3a48d3b1f --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/DTOs/ContainerRequestDetailDTO.cs @@ -0,0 +1,23 @@ +using System.ComponentModel.DataAnnotations; +using Volo.Abp.Data; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +/// +/// 器具呼叫明细DTO +/// +public class ContainerRequestDetailDTO : SfsStoreDetailWithQtyDTOBase, IHasExtraProperties +{ + /// + /// 呼叫库位 + /// + [Display(Name = "呼叫库位")] + public string ToLocationCode { get; set; } + + /// + /// 扩展属性 + /// + [Display(Name = "扩展属性")] + + public ExtraPropertyDictionary ExtraProperties { set; get; } = new ExtraPropertyDictionary(); +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/IContainerRequestAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/IContainerRequestAppService.cs new file mode 100644 index 000000000..91b383b91 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/IContainerRequestAppService.cs @@ -0,0 +1,11 @@ +using System.Threading.Tasks; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public interface IContainerRequestAppService + : ISfsStoreRequestMasterAppServiceBase + + + +{ +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/Inputs/ContainerRequestDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/Inputs/ContainerRequestDetailInput.cs new file mode 100644 index 000000000..64cb62bb2 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/Inputs/ContainerRequestDetailInput.cs @@ -0,0 +1,19 @@ +using System.ComponentModel.DataAnnotations; +using Volo.Abp.Data; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerRequestDetailInput : SfsStoreDetailWithQtyInputBase, IHasExtraProperties +{ + /// + /// 呼叫库位 + /// + [Display(Name = "呼叫库位")] + public string ToLocationCode { get; set; } + + /// + /// 扩展属性 + /// + [Display(Name = "扩展属性")] + public ExtraPropertyDictionary ExtraProperties { set; get; } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/Inputs/ContainerRequestEditInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/Inputs/ContainerRequestEditInput.cs new file mode 100644 index 000000000..25d984db2 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/Inputs/ContainerRequestEditInput.cs @@ -0,0 +1,36 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +/// +/// 新增和更新基础DTO +/// +public class ContainerRequestEditInput : SfsStoreRequestCreateOrUpdateInputBase +{ + #region Base + + [Display(Name = "呼叫库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + [StringLength(SfsEfCorePropertyConst.CodeLength, ErrorMessage = "{0}最多输入{1}个字符")] + public string RequestLocationCode { get; set; } + + #endregion + + #region Create + + [Display(Name = "器具类型")] + [Required(ErrorMessage = "{0}是必填项")] + public string ContainerType { get; set; } + + [Display(Name = "器具规格")] + [Required(ErrorMessage = "{0}是必填项")] + public string SpecificationsType { get; set; } + + [Display(Name = "明细列表")] + public List Details { get; set; } + #endregion +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/Inputs/ContainerRequestImportInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/Inputs/ContainerRequestImportInput.cs new file mode 100644 index 000000000..bdd2b6665 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/ContainerRequests/Inputs/ContainerRequestImportInput.cs @@ -0,0 +1,39 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; + +public class ContainerRequestImportInput : SfsStoreImportInputBase +{ + + /// + /// 呼叫库位代码 + /// + [Display(Name = "呼叫库位代码")] + [Required(ErrorMessage = "{0}是必填项")] + [ImporterHeader(Name = "呼叫库位代码")] + [ExporterHeader(DisplayName = "呼叫库位代码")] + public string RequestLocationCode { get; set; } + + /// + /// 器具类型 + /// + [Display(Name = "器具类型")] + [Required(ErrorMessage = "{0}是必填项")] + [ImporterHeader(Name = "器具类型")] + [ExporterHeader(DisplayName = "器具类型")] + public string ContainerType { get; set; } + + /// + /// 器具规格 + /// + [Display(Name = "器具规格")] + [Required(ErrorMessage = "{0}是必填项")] + [ImporterHeader(Name = "器具规格")] + [ExporterHeader(DisplayName = "器具规格")] + public string SpecificationsType { get; set; } + +} + diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/MaterialRequests/Inputs/MaterialRequestDetailInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/MaterialRequests/Inputs/MaterialRequestDetailInput.cs index df430f726..058c47f49 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/MaterialRequests/Inputs/MaterialRequestDetailInput.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/MaterialRequests/Inputs/MaterialRequestDetailInput.cs @@ -71,4 +71,15 @@ public class MaterialRequestDetailInput : SfsStoreDetailWithQtyInputBase [Display(Name = "明细状态")] public EnumStatus Status { get; set; } + /// + /// 位置码 + /// + public string PositionCode { get; set; } + + /// + /// 推荐类型 + /// + public EnumRecommendType RecommendType { get; set; } + + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReceiptRequests/IPurchaseReceiptRequestAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReceiptRequests/IPurchaseReceiptRequestAppService.cs index 8cb796843..9bb0ff309 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReceiptRequests/IPurchaseReceiptRequestAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReceiptRequests/IPurchaseReceiptRequestAppService.cs @@ -39,4 +39,21 @@ public interface IPurchaseReceiptRequestAppService /// Task UpdatePurchaseReceiptRequestAsync(string number, EnumRequestStatus enumRequestStatus); + + /// + /// 根据number取列表 + /// + /// + /// + Task> GetListByNumberAsync(string number); + + /// + /// 保存拆箱时涉及的明细修改 + /// + /// + /// + Task SaveDetail_SplitPackingAsync(SplitPacking_UpdateJobDetailInput input, string packingCode); + + + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReturnRequests/IPurchaseReturnRequestAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReturnRequests/IPurchaseReturnRequestAppService.cs index 9fea10b59..76ad6e798 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReturnRequests/IPurchaseReturnRequestAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReturnRequests/IPurchaseReturnRequestAppService.cs @@ -1,3 +1,5 @@ +using System.Collections.Generic; +using System.Threading.Tasks; using Win_in.Sfs.Shared.Application.Contracts; namespace Win_in.Sfs.Wms.Store.Application.Contracts; @@ -7,5 +9,5 @@ public interface IPurchaseReturnRequestAppService , ISfsCheckStatusAppService { - + Task> CreateManyAsync(List inputs); } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReturnRequests/Inputs/PurchaseReturnRequestPdaInput.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReturnRequests/Inputs/PurchaseReturnRequestPdaInput.cs new file mode 100644 index 000000000..b00091f9b --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application.Contracts/Requests/PurchaseReturnRequests/Inputs/PurchaseReturnRequestPdaInput.cs @@ -0,0 +1,56 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using DocumentFormat.OpenXml.Wordprocessing; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application.Contracts; +public class PurchaseReturnRequestPdaInput : SfsStoreDetailWithLotPackingQtyLocationStatusInputBase, IHasPoLine +{ + /// + /// 收货单号 + /// + [Display(Name = "收货单号")] + public string RpNumber { get; set; } + + /// + /// 发货单号 + /// + [Display(Name = "发货单号")] + public string AsnNumber { get; set; } + + /// + /// 订单号 + /// + [Display(Name = "订单号")] + public string PoNumber { get; set; } + + /// + /// 供应商代码 + /// + [Display(Name = "供应商代码")] + public string SupplierCode { get; set; } + + /// + /// 退货类型 + /// + [Display(Name = "退货类型")] + public EnumPurchaseReturnType ReturnType { get; set; } = EnumPurchaseReturnType.AfterPuton; + + /// + /// 订单行 + /// + [Display(Name = "订单行")] + public string PoLine { get; set; } + + /// + /// 供应商包装 + /// + [Display(Name = "供应商包装")] + public decimal SupplierPackQty { get; set; } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Equipments/EquipmentRecordAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Equipments/EquipmentRecordAppService.cs new file mode 100644 index 000000000..a57637e3b --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Equipments/EquipmentRecordAppService.cs @@ -0,0 +1,129 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Castle.Components.DictionaryAdapter; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; +using Microsoft.EntityFrameworkCore; +using Volo.Abp; +using Volo.Abp.Domain.Entities; +using Volo.Abp.Domain.Repositories; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Equipments.DTOs; +using Win_in.Sfs.Shared.Application; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Domain.Shared; +using Win_in.Sfs.Wms.Store.Equipments; + +namespace Win_in.Sfs.Wms.Store.Application; + +[Authorize] +[Route($"{StoreConsts.RootPath}EquipmentRecord")] +public class EquipmentRecordAppService + : SfsStoreAppServiceBase + , IEquipmentRecordAppService + +{ + private readonly IEquipmentRecordManager _manager; + private readonly IEquipmentRecordRepository _repository; + + public EquipmentRecordAppService( + IEquipmentRecordRepository repository, IEquipmentRecordManager manager + ):base(repository) + { + base.CreatePolicyName = EquipmentRecordPermissions.Create; + base.UpdatePolicyName = EquipmentRecordPermissions.Update; + base.DeletePolicyName = EquipmentRecordPermissions.Delete; + + _manager = manager; + _repository = repository; + } + /// + /// 绑定器具记录 + /// + /// + /// + /// + [HttpPost("Bind")] + public Task> Bind(List p_ls) + { + return _manager.Bind(p_ls); + } + + /// + /// 解绑器具记录 + /// + /// + /// + /// + [HttpPost("UnBind")] + public Task> UnBind(List p_ls) + { + return _manager.UnBind(p_ls); + } + + /// + /// 没用 + /// + /// + /// + /// + /// + [HttpPost("addDetail")] + public Task AddDetailListAsync(Guid id, List list) + { + throw new NotImplementedException(); + } + + + + /// + /// 没用 + /// + [HttpPost("check")] + public Task CheckStatusAsync(string number) + { + throw new NotImplementedException(); + } + /// + /// 没用 + /// + [HttpPost("getlist")] + public Task> GetDetailListAsync(Guid id, SfsStoreRequestInputBase requestInput) + { + throw new NotImplementedException(); + } + + + /// + /// 没用 + /// + [HttpPost("updateDetail")] + public Task UpdateDetailAsync(Guid id, Guid detailId, EquipmentRecordDTO updateDTO) + { + throw new NotImplementedException(); + } + /// + /// 没用 + /// + [HttpPost("upsertAsync")] + public Task UpsertAsync(EquipmentRecordEditInput input) + { + throw new NotImplementedException(); + } + /// + /// 没用 + /// + [HttpPost("withDetil")] + Task ISfsReadOnlyWithDetailsAppService.GetDetailAsync(Guid id, Guid detailId) + { + throw new NotImplementedException(); + } + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Equipments/EquipmentRecordAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Equipments/EquipmentRecordAutoMapperProfile.cs new file mode 100644 index 000000000..bbffa0718 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Equipments/EquipmentRecordAutoMapperProfile.cs @@ -0,0 +1,43 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain; +using Win_in.Sfs.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Equipments; + +namespace Win_in.Sfs.Wms.Store.Application; + +public partial class StoreApplicationAutoMapperProfile : Profile +{ + private void EquipmentRecordAutoMapperProfile() + { + CreateMap() + .ReverseMap(); + // CreateMap() + // .IgnoreAuditedObjectProperties() + // .Ignore(x => x.ConcurrencyStamp).Ignore(x => x.Id) + // ; + // CreateMap() + // .IgnoreAuditedObjectProperties() + // .Ignore(x => x.Id) ; + // ; + + // CreateMap() + // .IgnoreAuditedObjectProperties() + // .Ignore(x => x.TenantId) + // //.Ignore(x => x.Remark) + // .Ignore(x => x.ExtraProperties) + // .Ignore(x => x.ConcurrencyStamp) + // ; + + // CreateMap() + // .Ignore(x => x.ReportStatus) + // .Ignore(x => x.ReportReason) + // ; + + // CreateMap() + //; + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ContainerJobs/ContainerJobAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ContainerJobs/ContainerJobAppService.cs new file mode 100644 index 000000000..76328726a --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ContainerJobs/ContainerJobAppService.cs @@ -0,0 +1,65 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Linq.Expressions; +using System.Threading; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp; +using Volo.Abp.Application.Dtos; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application; + +[Authorize] +[Route($"{StoreConsts.RootPath}container-job")] + +public class ContainerJobAppService + : SfsJobAppServiceBase, + IContainerJobAppService +{ + private readonly IContainerJobManager _ContainerJobManager; + + public ContainerJobAppService( + IContainerJobRepository repository, IContainerJobManager ContainerJobManager + ) : base(repository, ContainerJobManager) + { + _ContainerJobManager = ContainerJobManager; + } + + /// + /// 根据库位 检查是否存在任务 + /// + /// + /// + /// + /// + [Authorize] + [HttpGet("check-job-exist")] + public virtual async Task> CheckJobExistByItemCodeAndLocationCode(string itemCode, + string locationCode) + { + var entities = await _repository.GetListAsync(c => + c.Details.Any(p => + (p.ItemCode == itemCode && p.RecommendFromLocationCode == locationCode) || + (p.ItemCode == itemCode && p.ToLocationCode == locationCode)) + && (c.JobStatus == EnumJobStatus.Open || c.JobStatus == EnumJobStatus.Doing), true).ConfigureAwait(false); + var dtos = ObjectMapper.Map, List>(entities); + return dtos; + } + + [HttpPost("by-request-number/{requestNumber}")] + public virtual async Task> GetByRequestNumberAsync(string requestNumber) + { + var entitys = await _repository.GetListAsync(p => p.ContainerRequestNumber == requestNumber).ConfigureAwait(false); + return ObjectMapper.Map, List>(entitys); + } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ContainerJobs/ContainerJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ContainerJobs/ContainerJobAutoMapperProfile.cs new file mode 100644 index 000000000..e4a1a38e9 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ContainerJobs/ContainerJobAutoMapperProfile.cs @@ -0,0 +1,32 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Application; + +public partial class StoreApplicationAutoMapperProfile : Profile +{ + private void ContainerJobAutoMapperProfile() + { + CreateMap() + .Ignore(x => x.SpecificationsTypeName); + + CreateMap() + ; + + CreateMap() + ; + + CreateMap() + ; + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.MasterID) + .Ignore(x => x.TenantId) + .Ignore(x => x.Number) + .Ignore(x => x.Id); + + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/InspectJobs/InspectJobAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/InspectJobs/InspectJobAppService.cs index 1f534b9e1..9ecba3c87 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/InspectJobs/InspectJobAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/InspectJobs/InspectJobAppService.cs @@ -4,7 +4,9 @@ using System.Text.Json; using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; +using Volo.Abp; using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Domain.Shared; using Win_in.Sfs.FileStorage.Application.Contracts; using Win_in.Sfs.Wms.Store.Application.Contracts; using Win_in.Sfs.Wms.Store.Domain; @@ -160,6 +162,38 @@ public class InspectJobAppService return dto; } + /// + /// 保存拆箱时涉及的明细修改 + /// + /// + [HttpPost("save-detail-split-packing")] + public virtual async Task SaveDetail_SplitPackingAsync(SplitPacking_UpdateJobDetailInput input) + { + InspectJob job = await _repository.FindAsync(p => p.Number == input.Number).ConfigureAwait(false); + InspectJobDetail detail = job.Details.FirstOrDefault(p => p.PackingCode == input.FromPackingCode); /* && p.ReceiveQty == input.FromQty*/ + if (detail == null) + { + throw new UserFriendlyException($"根据PackingCode={input.FromPackingCode}取InspectDetail表为空!"); + } + //插入目标箱 + var newDetail = CommonHelper.CloneObj(detail); + newDetail.SetId(GuidGenerator.Create()); + newDetail.PackingCode = input.ToPackingCode; + newDetail.ReceiveQty = input.ToQty; + newDetail.InspectQty = input.ToQty; + newDetail.GoodQty = input.ToQty; + //newDetail.CreationTime = CommonHelper.CurTime; + job.Details.Add(newDetail); + //修改源箱 + detail.ReceiveQty = input.FromQty - input.ToQty; + detail.InspectQty = input.FromQty - input.ToQty; + detail.GoodQty = input.FromQty - input.ToQty; + var entity = await _repository.UpdateAsync(job).ConfigureAwait(false); + var ret = ObjectMapper.Map(entity); + return ret; + } + + //[HttpPost("pick-inspect")] //public virtual async Task AddPickInspectJobAsync(InspectJobCreateInput input) //{ diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/IssueJobs/IssueJobAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/IssueJobs/IssueJobAppService.cs index 6ec183a2b..f1e5d8d17 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/IssueJobs/IssueJobAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/IssueJobs/IssueJobAppService.cs @@ -9,6 +9,7 @@ using Microsoft.AspNetCore.Mvc; using Volo.Abp; using Volo.Abp.Application.Dtos; using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Domain.Shared; using Win_in.Sfs.Shared.Domain; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.Store.Application.Contracts; @@ -159,6 +160,38 @@ public class IssueJobAppService return ObjectMapper.Map, List>(entitys); } + /// + /// 保存拆箱时涉及的明细修改 + /// + /// + [HttpPost("save-detail-split-packing")] + public virtual async Task SaveDetail_SplitPackingAsync(SplitPacking_UpdateJobDetailInput input) + { + var job = await _repository.FindAsync(p => p.Number == input.Number).ConfigureAwait(false); + IssueJobDetail detail = job.Details.FirstOrDefault(p => p.RecommendPackingCode == input.FromPackingCode ); /*&& p.HandledQty == input.FromQty*/ + if (detail == null) + { + //throw new UserFriendlyException($"根据HandledPackingCode={input.FromPackingCode}取IssueJobDetail表为空!"); + throw new UserFriendlyException($"根据RecommendPackingCode={input.FromPackingCode}取IssueJobDetail表为空!"); + } + //插入目标箱 + var newDetail = CommonHelper.CloneObj(detail); + newDetail.SetId(GuidGenerator.Create()); + newDetail.RecommendPackingCode = input.ToPackingCode; + newDetail.RecommendQty = input.ToQty; + newDetail.HandledPackingCode = detail.HandledPackingCode.HasValue() ? input.ToPackingCode : null; //源实际实际箱码有值,则新记录实际箱码有值 + newDetail.HandledQty = detail.HandledQty > 0 ? input.ToQty : 0; + //newDetail.CreationTime = CommonHelper.CurTime; + job.Details.Add(newDetail); + //修改源箱 + detail.RecommendQty = input.FromQty - input.ToQty; + detail.HandledQty = detail.HandledQty > 0 ? input.FromQty - input.ToQty : 0; + var entity = await _repository.UpdateAsync(job).ConfigureAwait(false); + var ret = ObjectMapper.Map(entity); + return ret; + } + + /* /// /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductRecycleJobs/ProductRecycleJobAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductRecycleJobs/ProductRecycleJobAppService.cs new file mode 100644 index 000000000..a7842a0b5 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductRecycleJobs/ProductRecycleJobAppService.cs @@ -0,0 +1,28 @@ +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application; + +[Authorize] +[Route($"{StoreConsts.RootPath}production-recycle-job")] + +public class ProductRecycleJobAppService + : SfsJobAppServiceBase + , IProductRecycleJobAppService +{ + private readonly IProductRecycleJobManager _productRecycleJobManager; + + public ProductRecycleJobAppService( + IProductRecycleJobRepository repository, IProductRecycleJobManager productRecycleJobManager) + : base(repository, productRecycleJobManager) + { + _productRecycleJobManager = productRecycleJobManager; + } + + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductRecycleJobs/ProductRecycleJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductRecycleJobs/ProductRecycleJobAutoMapperProfile.cs new file mode 100644 index 000000000..a58f3029c --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/ProductRecycleJobs/ProductRecycleJobAutoMapperProfile.cs @@ -0,0 +1,31 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Application; + +public partial class StoreApplicationAutoMapperProfile : Profile +{ + private void ProductRecycleJobAutoMapperProfile() + { + CreateMap() + .ReverseMap(); + + CreateMap() + ; + + CreateMap(); + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.MasterID) + .Ignore(x => x.TenantId) + .Ignore(x => x.Number) + .Ignore(x => x.Id); + + CreateMap() + ; + + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobAppService.cs index 2c646ae7e..ec046020f 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobAppService.cs @@ -5,7 +5,9 @@ using System.Text.Json; using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; +using Volo.Abp; using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Domain.Shared; using Win_in.Sfs.FileStorage.Application.Contracts; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.Store.Application.Contracts; @@ -214,6 +216,54 @@ public class PurchaseReceiptJobAppService : return dto; } + /// + /// 根据number取列表 + /// + /// + /// + [HttpGet("get-list-by-number")] + public async Task> GetListByNumberAsync(string number) + { + var entity = await _repository.GetListAsync(itm => itm.Number == number).ConfigureAwait(false); + var dto = ObjectMapper.Map, List>(entity); + return dto; + } + + /// + /// 保存拆箱时涉及的明细修改 + /// + /// + [HttpPost("save-detail-split-packing")] + public virtual async Task SaveDetail_SplitPackingAsync(SplitPacking_UpdateJobDetailInput input) + { + var job = await _repository.FindAsync(p => p.Number == input.Number).ConfigureAwait(false); + PurchaseReceiptJobDetail detail = job.Details.FirstOrDefault(p => p.RecommendPackingCode == input.FromPackingCode); /* && p.RecommendQty == input.FromQty*/ + if (detail == null) + { + //throw new UserFriendlyException($"根据HandledPackingCode={input.FromPackingCode}取ReceiptRequestDetail表为空!"); + throw new UserFriendlyException($"根据RecommendPackingCode={input.FromPackingCode}取PurchaseReceiptJobDetail表为空!"); + + } + //插入目标箱 + var newDetail = CommonHelper.CloneObj(detail); + newDetail.SetId(GuidGenerator.Create()); + newDetail.RecommendPackingCode = input.ToPackingCode; + newDetail.RecommendQty = input.ToQty; + newDetail.HandledPackingCode = detail.HandledPackingCode.HasValue() ? input.ToPackingCode : null; //源实际实际箱码有值,则新记录实际箱码有值 + newDetail.HandledQty = detail.HandledQty > 0 ? input.ToQty : 0; + //newDetail.CreationTime = CommonHelper.CurTime; + job.Details.Add(newDetail); + //修改源箱 + detail.RecommendQty = input.FromQty - input.ToQty; + detail.HandledQty = detail.HandledQty > 0 ? input.FromQty - input.ToQty : 0; + var entity = await _repository.UpdateAsync(job).ConfigureAwait(false); + var ret = ObjectMapper.Map(entity); + return ret; + } + + + + ///// ///// 取消请求 ///// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ContainerNotes/ContainerNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ContainerNotes/ContainerNoteAppService.cs new file mode 100644 index 000000000..40daa772d --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ContainerNotes/ContainerNoteAppService.cs @@ -0,0 +1,75 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Linq.Expressions; +using System.Threading; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; +using Volo.Abp; +using Volo.Abp.Application.Dtos; +using Volo.Abp.Domain.Entities; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Event; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application; + +[Authorize] +[Route($"{StoreConsts.RootPath}container-note")] +public class ContainerNoteAppService : + SfsStoreWithDetailsAppServiceBase, + IContainerNoteAppService +{ + private readonly IContainerNoteManager _ContainerNoteManager; + + public ContainerNoteAppService( + IContainerNoteRepository repository, + IContainerNoteManager ContainerNoteManager + ) : base(repository) + { + _ContainerNoteManager = ContainerNoteManager; + } + + [HttpPost("")] + //[Authorize(ContainerNotePermissions.Create)] + public override async Task CreateAsync(ContainerNoteEditInput input) + { + var entity = ObjectMapper.Map(input); + await _ContainerNoteManager.CreateAsync(entity).ConfigureAwait(false); + var dto = ObjectMapper.Map(entity); + return dto; + } + + /// + /// 确认对应的记录单 + /// + /// + /// + [HttpPost("confirm/{id}")] + public virtual async Task ConfirmAsync(Guid id) + { + var ContainerNote= await _repository.GetAsync(id).ConfigureAwait(false); + ContainerNote.Confirmed = true; + ContainerNote=await _repository.UpdateAsync(ContainerNote).ConfigureAwait(false); + await LocalEventBus.PublishAsync(new SfsConfirmedEntityEventData(ContainerNote), false).ConfigureAwait(false); + return ObjectMapper.Map(ContainerNote); + } + + [HttpPost("confirm-by-number/{number}")] + public virtual async Task ConfirmAsync(string number) + { + var entity = await _repository.FindAsync(p => p.Number == number).ConfigureAwait(false); + Check.NotNull(entity, nameof(ContainerNote)); + var result = await _ContainerNoteManager.ConfirmAsync(entity.Id).ConfigureAwait(false); + var dto = ObjectMapper.Map(result); + return dto; + } + + + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ContainerNotes/ContainerNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ContainerNotes/ContainerNoteAutoMapperProfile.cs new file mode 100644 index 000000000..6d7d3723a --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ContainerNotes/ContainerNoteAutoMapperProfile.cs @@ -0,0 +1,31 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Application; + +public partial class StoreApplicationAutoMapperProfile : Profile +{ + private void ContainerNoteAutoMapperProfile() + { + CreateMap() + .ReverseMap(); + + CreateMap(); + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.MasterID) + .Ignore(x => x.TenantId) + .Ignore(x => x.Number) + .Ignore(x => x.Id); + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.TenantId) + .Ignore(x => x.Number) + .Ignore(x => x.Id); + ; + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ItemTransformNotes/ItemTransformNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ItemTransformNotes/ItemTransformNoteAppService.cs index 0d361afa1..034634fd8 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ItemTransformNotes/ItemTransformNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ItemTransformNotes/ItemTransformNoteAppService.cs @@ -20,13 +20,16 @@ public class ItemTransformNoteAppService : { private readonly IItemTransformNoteManager _ItemTransformNoteManager; private readonly ILocationCapacityAppService _locationCapacityAppService; + private readonly IRecycledMaterialReceiptNoteAppService _recycledMaterialReceiptNoteAppService; public ItemTransformNoteAppService(IItemTransformNoteRepository repository, IItemTransformNoteManager ItemTransformNoteManager, - ILocationCapacityAppService locationCapacityAppService) : base(repository) + ILocationCapacityAppService locationCapacityAppService, + IRecycledMaterialReceiptNoteAppService recycledMaterialReceiptNoteAppService) : base(repository) { _ItemTransformNoteManager = ItemTransformNoteManager; _locationCapacityAppService = locationCapacityAppService; + _recycledMaterialReceiptNoteAppService = recycledMaterialReceiptNoteAppService; } [HttpPost("")] @@ -41,4 +44,18 @@ public class ItemTransformNoteAppService : return dto; } + + [HttpPost("new-create")] + //[Authorize(ItemTransformNotePermissions.Create)] + public async Task NewCreateAsync(ItemTransformNoteEditInput input) + { + var entity = ObjectMapper.Map(input); + await _ItemTransformNoteManager.CreateAsync(entity).ConfigureAwait(false); + var recInput = ObjectMapper.Map(input); + await _recycledMaterialReceiptNoteAppService.NewCreateAsync(recInput).ConfigureAwait(false); + var dto = ObjectMapper.Map(entity); + + return dto; + } + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ItemTransformNotes/ItemTransformNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ItemTransformNotes/ItemTransformNoteAutoMapperProfile.cs index 341d1b2ac..dce86437e 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ItemTransformNotes/ItemTransformNoteAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ItemTransformNotes/ItemTransformNoteAutoMapperProfile.cs @@ -30,7 +30,12 @@ public partial class StoreApplicationAutoMapperProfile : Profile .Ignore(x => x.Number) .Ignore(x => x.Id) .Ignore(x=>x.ExtraProperties) - .Ignore(x => x.Remark) - ; + .Ignore(x => x.Remark); + CreateMap() + .ForMember(x => x.Details, y => y.MapFrom(d => d.RecDetails)) + .Ignore(x => x.TenantId) + .Ignore(x => x.Number) + .Ignore(x => x.ExtraProperties) + .Ignore(x => x.Remark); } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ProductRecycleNotes/ProductRecycleNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ProductRecycleNotes/ProductRecycleNoteAppService.cs index db384ee8f..4e3ec69d7 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ProductRecycleNotes/ProductRecycleNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/ProductRecycleNotes/ProductRecycleNoteAppService.cs @@ -13,6 +13,7 @@ using System.Collections.Generic; using System.Linq; using Volo.Abp.Data; using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Wms.Store.Notes.ProductRecycleNotes.DTOs; /// /// 成品回收记录 @@ -91,6 +92,60 @@ public class ProductRecycleNoteAppService : } } + + /// + /// 导出报废 + /// + [HttpPost("export-scrap")] + public virtual async Task ExportScrapAsync(SfsExportRequestInput requestInput) + { + try + { + var pagedResult = await GetPagedListByFilterAsync( + new SfsStoreRequestInputBase() { Condition = requestInput.Condition }, + true).ConfigureAwait(false); + + var items = pagedResult.Items.ToList(); + + await SetNoteAndBackFlushDetailsAsync(pagedResult.Items.ToList()).ConfigureAwait(false); + + var exports = BuildProductRecycleNoteAndBackFlushDetailExport(items); + List exportlist=new List(); + foreach (var itm in exports) + { + exportlist.Add(new ProductRecycleNoteDetailExtendDto() + { + + ItemCode = itm.ItemCode, + LocCode = itm.LocationCode, + Reason = string.Empty, + Qty = itm.Qty, + Type = "客户退拆" + + + + }); + } + + + + return ExportImportService.Export(exports); + } + catch (Exception ex) + { + Logger.LogException(ex); + throw new Exception(ex.Message); + } + } + + + + + + + + + protected virtual async Task SetNoteAndBackFlushDetailsAsync(List dtos) { await Task.CompletedTask.ConfigureAwait(false); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAppService.cs index ea0259e7a..f218f9a99 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAppService.cs @@ -5,6 +5,7 @@ using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Basedata.Application.Contracts; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.Store.Application.Contracts; using Win_in.Sfs.Wms.Store.Domain; @@ -21,13 +22,16 @@ public class PurchaseReceiptNoteAppService : IPurchaseReceiptNoteAppService { private readonly IPurchaseReceiptNoteManager _purchaseReceiptNoteManager; + private readonly ISplitPackingRecAppService _splitPackingRecAppService; public PurchaseReceiptNoteAppService( IPurchaseReceiptNoteRepository repository , IPurchaseReceiptNoteManager purchaseReceiptNoteManager + , ISplitPackingRecAppService splitPackingRecAppService ) : base(repository) { _purchaseReceiptNoteManager = purchaseReceiptNoteManager; + _splitPackingRecAppService = splitPackingRecAppService; } [HttpPost("get-list-by-po/{poNumber}")] @@ -74,11 +78,34 @@ public class PurchaseReceiptNoteAppService : /// /// [HttpGet("detail-no-ok/{id}")] - public virtual async Task> GetDetailListByNoOkAsync(Guid id) + public virtual async Task> GetDetailListByNoOkAsync(Guid id) { var entity = await _repository.FindAsync(p => p.Id == id).ConfigureAwait(false); - return ObjectMapper.Map, List>(entity.Details + + var lst = ObjectMapper.Map, List>(entity.Details .Where(p => p.PurchaseReceiptInspectStatus == EnumPurchaseReceiptInspect.NOK).ToList()); + + if (lst.Count == 0) + { + return lst; + } + + #region 从拆箱记录表中取源箱码、目标箱码赋值给结果列表 + List strLst = lst.Select(itm => itm.PackingCode).Distinct().ToList(); + List splitPackingRecLst = await _splitPackingRecAppService.GetListByToPackingCode(strLst).ConfigureAwait(false); + + foreach (var item in lst) + { + var obj = splitPackingRecLst.FirstOrDefault(itm => itm.FromPackingCode == item.PackingCode); + if (obj != null) + { + item.FromPackingCode = obj.FromPackingCode; + item.ToPackingCode = obj.ToPackingCode; + } + } + #endregion + + return lst; } /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAutoMapperProfile.cs index b4877764b..549d38639 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PurchaseReceiptNotes/PurchaseReceiptNoteAutoMapperProfile.cs @@ -16,6 +16,12 @@ public partial class StoreApplicationAutoMapperProfile : Profile CreateMap() .ReverseMap(); + CreateMap() + .Ignore(x => x.FromPackingCode) + .Ignore(x => x.ToPackingCode) + .ReverseMap(); + + CreateMap() .IgnoreAuditedObjectProperties() .Ignore(x => x.MasterID) diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PutawayNotes/PutawayNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PutawayNotes/PutawayNoteAppService.cs index b7c51fa86..96813e3c8 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PutawayNotes/PutawayNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/PutawayNotes/PutawayNoteAppService.cs @@ -28,16 +28,19 @@ public class PutawayNoteAppService : private readonly IPutawayNoteManager _putawayNoteManager; private readonly IPurchaseReceiptNoteAppService _purchaseReceiptNoteAppService; public readonly IInspectJobAppService _inspectJobAppService; + public readonly IPurchaseOrderManager _purchaseOrderManager; public PutawayNoteAppService( IPutawayNoteRepository repository, IPutawayNoteManager putawayNoteManager, IPurchaseReceiptNoteAppService purchaseReceiptNoteAppService, - IInspectJobAppService inspectJobAppService) : base(repository) + IInspectJobAppService inspectJobAppService, + IPurchaseOrderManager purchaseOrderManager) : base(repository) { _putawayNoteManager = putawayNoteManager; _purchaseReceiptNoteAppService = purchaseReceiptNoteAppService; _inspectJobAppService = inspectJobAppService; + _purchaseOrderManager = purchaseOrderManager; } /// @@ -53,6 +56,11 @@ public class PutawayNoteAppService : { try { + var isClosed = await _purchaseOrderManager.CheckIsCloseAsync(input.Number,input.SupplierCode, detail.ItemCode).ConfigureAwait(false); + if (isClosed) + { + throw new UserFriendlyException($"零件名称【{detail.ItemCode}】的订单明细行以关闭无法执行采购上价!"); + } var purchasereDetail = await _purchaseReceiptNoteAppService .GetDetailByItemAndPackingAsync(detail.ItemCode, detail.ToPackingCode).ConfigureAwait(false); if (purchasereDetail != null) @@ -214,4 +222,24 @@ public class PutawayNoteAppService : return dtos; } + [HttpPost("print-update-remark/{id}")] + public virtual async Task PrintUpdateRemark(Guid id) + { + bool result = true; + try + { + var entitie = await _repository.GetAsync(p => p.Id == id).ConfigureAwait(false); + if (entitie != null) + { + entitie.Remark = "已打印"; + } + await _repository.UpdateAsync(entitie).ConfigureAwait(false); + + } + catch (Exception) + { + result = false; + } + return result; + } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAppService.cs index 3e09d396c..c66029c60 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/RecycledMaterialReceiptNotes/RecycledMaterialReceiptNoteAppService.cs @@ -78,4 +78,38 @@ public class RecycledMaterialReceiptNoteAppService : return ObjectMapper.Map(entity); } + + /// + /// 新增实体 + /// + /// CreateInput + [HttpPost("new-create")] + public async Task NewCreateAsync(RecycledMaterialReceiptNoteEditInput input) + { + var entity = ObjectMapper.Map(input); + + entity.Number = string.IsNullOrEmpty(input.Number) + ? await GenerateNumberAsync(nameof(RecycledMaterialReceiptNote), input.ActiveDate) + .ConfigureAwait(false) + : input.Number; + entity.SetId(GuidGenerator.Create()); + + foreach (var detail in entity.Details) + { + var detailNumber = await GenerateNumberAsync(nameof(RecycledMaterialReceiptNote), input.ActiveDate) + .ConfigureAwait(false); + detail.SetIdAndNumber(GuidGenerator, entity.Id, detailNumber); + var locationDto = await _locationAppService.GetByCodeAsync(detail.LocationCode).ConfigureAwait(false); + detail.LocationErpCode = locationDto.ErpLocationCode; + detail.LocationArea = locationDto.AreaCode; + detail.LocationGroup = locationDto.LocationGroupCode; + detail.WarehouseCode = locationDto.WarehouseCode; + var itemBasicDto = await _itemBasicAppService.GetByCodeAsync(detail.ItemCode).ConfigureAwait(false); + detail.StdPackQty = itemBasicDto.StdPackQty; + detail.Uom = itemBasicDto.BasicUom; + } + + entity = await _repository.InsertAsync(entity).ConfigureAwait(false); + return ObjectMapper.Map(entity); + } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/TransferNotes/TransferNoteAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/TransferNotes/TransferNoteAppService.cs index d1d5c3dd4..2848d8650 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/TransferNotes/TransferNoteAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Notes/TransferNotes/TransferNoteAppService.cs @@ -9,6 +9,8 @@ using Microsoft.EntityFrameworkCore; using Volo.Abp; using Volo.Abp.Application.Dtos; using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Basedata.SplitPackings.Commons; using Win_in.Sfs.Shared.Domain; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.Inventory.Application.Contracts; @@ -31,16 +33,39 @@ public class TransferNoteAppService : SfsStoreWithDetailsAppServiceBase private readonly ITransferNoteManager _transferNoteManager; private readonly IBalanceAppService _balanceAppService; private readonly ILocationAppService _locationAppService; + private readonly ISplitPackingRecAppService _splitPackingRecAppService; + private readonly IPurchaseReceiptJobAppService _purchaseReceiptJobAppService; + private readonly IPurchaseReceiptRequestAppService _purchaseReceiptRequestAppService; //采购收货 + private readonly IInspectJobAppService _inspectJobAppService; //质检 + private readonly IIssueJobAppService _issueJobAppService; //发料 + + private readonly IExpectOutAppService _expectOutAppService; // + + + + public TransferNoteAppService( ITransferNoteRepository repository, ITransferNoteManager transferNoteManager, IBalanceAppService balanceAppService, - ILocationAppService locationAppService) : base(repository) + ILocationAppService locationAppService, + ISplitPackingRecAppService splitPackingRecAppService, + IPurchaseReceiptJobAppService purchaseReceiptJobAppService, + IPurchaseReceiptRequestAppService purchaseReceiptRequestAppService, + IInspectJobAppService inspectJobAppService, + IIssueJobAppService issueJobAppService, + IExpectOutAppService expectOutAppService) : base(repository) { _transferNoteManager = transferNoteManager; _balanceAppService = balanceAppService; _locationAppService = locationAppService; + _splitPackingRecAppService = splitPackingRecAppService; + _purchaseReceiptJobAppService = purchaseReceiptJobAppService; + _purchaseReceiptRequestAppService = purchaseReceiptRequestAppService; + _inspectJobAppService = inspectJobAppService; + _issueJobAppService = issueJobAppService; + _expectOutAppService = expectOutAppService; } #region 东阳使用 @@ -121,6 +146,9 @@ public class TransferNoteAppService : SfsStoreWithDetailsAppServiceBase [HttpPost("split-packing")] public async Task SplitPackingAsync(TransferNoteEditInput transferNoteEditInput) { + //插入拆箱记录表 + await WriteSplitPackingRec(transferNoteEditInput).ConfigureAwait(false); + //更新库存 transferNoteEditInput.Type = EnumTransSubType.Transfer_SplitPacking.ToString(); return await CreateAsync(transferNoteEditInput).ConfigureAwait(false); } @@ -353,5 +381,132 @@ public class TransferNoteAppService : SfsStoreWithDetailsAppServiceBase return dto; } - + /// + /// 插入拆箱记录表 + /// + /// + /// + private async Task WriteSplitPackingRec(TransferNoteEditInput transferNoteEditInput) + { + List recLst = new List(); + foreach (var inputDetail in transferNoteEditInput.Details) + { + SplitPackingRecEditInput packRec = new SplitPackingRecEditInput(); + packRec.OprType = OprTypeEnum.SplitBox; + packRec.FromPackingCode = inputDetail.FromPackingCode; + //packRec.FromTopPackingCode = inputDetail.; + packRec.FromStdPackQty = inputDetail.StdPackQty; + packRec.FromUom = inputDetail.Uom; + packRec.FromQty = inputDetail.Qty; + packRec.ToPackingCode = inputDetail.ToPackingCode; + //packRec.ToTopPackingCode = inputDetail.; + packRec.ToStdPackQty = inputDetail.StdPackQty; + packRec.ToUom = inputDetail.Uom; + packRec.ToQty = inputDetail.Qty; + packRec.ItemCode = inputDetail.ItemCode; + packRec.ItemName = inputDetail.ItemName; + packRec.ItemDesc1 = inputDetail.ItemDesc1; + packRec.ItemDesc2 = inputDetail.ItemDesc2; + packRec.FromLot = inputDetail.FromLot; + packRec.ToLot = inputDetail.ToLot; + //packRec.PurchaseInfo_PoNumber = inputDetail.; // 采购订单 + //packRec.PurchaseInfo_AsnNumber = inputDetail.; //供应商发货单 + //packRec.ArrivalNoticNumber = inputDetail.; //到货通知 + //packRec.TaskOrderNumber = inputDetail.; //任务单 + //packRec.ReceiptRecNumber = inputDetail.; //收货记录单 + //packRec.PutOnShelfNumber = inputDetail.; //上架单 + recLst.Add(packRec); + } + var ret = await _splitPackingRecAppService.BatchInsertAsync(recLst).ConfigureAwait(false); + return ret; + } + + /// + /// 采购收货拆箱,同时更新、插入PurchaseReceipt任务表、申请表 + /// + /// + /// + /// + [HttpPost("split-packing-purchase-receipt")] + public async Task SplitPacking_PurchaseReceiptAsync(TransferNoteEditInput transferNoteEditInput, [FromQuery] SplitPacking_UpdateJobDetailInput updateJobDetailInput) + { + var jobRet = await _purchaseReceiptJobAppService.SaveDetail_SplitPackingAsync(updateJobDetailInput).ConfigureAwait(false); + var requestRet = await _purchaseReceiptRequestAppService.SaveDetail_SplitPackingAsync(updateJobDetailInput, jobRet.PurchaseReceiptRequestNumber).ConfigureAwait(false); + bool ret = await WriteSplitPackingRec(transferNoteEditInput).ConfigureAwait(false); //采购收货-目检-拆箱时,还没有入库,不涉及库存操作 + return ret; + } + + /// + /// 质检拆箱,同时更新、插入Inspect任务表(不更新申请表) + /// + /// + /// + /// + [HttpPost("split-packing-inspect")] + public async Task SplitPacking_InspectAsync(TransferNoteEditInput transferNoteEditInput, [FromQuery] SplitPacking_UpdateJobDetailInput updateJobDetailInput) + { + //SplitPacking_UpdateDetailInput newInput = new SplitPacking_UpdateDetailInput(); + //newInput.Number = updateJobDetailInput.Number; + //newInput.FromPackingCode = updateJobDetailInput.FromPackingCode; + //newInput.FromQty = updateJobDetailInput.FromQty; + //newInput.ToPackingCode = updateJobDetailInput.ToPackingCode; + //newInput.ToQty = updateJobDetailInput.ToQty; + //newInput.FromLocationCode = transferNoteEditInput.Details[0].FromLocationCode; + //newInput.ToLocationCode = transferNoteEditInput.Details[0].ToLocationCode; + //var expectOutRet = await _expectOutAppService.SaveDetail_SplitPackingAsync(newInput).ConfigureAwait(false); + var jobRet = await _inspectJobAppService.SaveDetail_SplitPackingAsync(updateJobDetailInput).ConfigureAwait(false); + var ret = await SplitPackingAsync(transferNoteEditInput).ConfigureAwait(false); //库存操作 + return ret; + } + + /// + /// 发料拆箱,同时更新、插入Inspect任务表(没有找到申请表//??) + /// + /// + /// + /// + [HttpPost("split-packing-issue")] + public async Task SplitPacking_IssueAsync(TransferNoteEditInput transferNoteEditInput, [FromQuery] SplitPacking_UpdateJobDetailInput updateJobDetailInput) + { + SplitPacking_UpdateDetailInput newInput = new SplitPacking_UpdateDetailInput(); + newInput.Number = updateJobDetailInput.Number; + newInput.FromPackingCode = updateJobDetailInput.FromPackingCode; + newInput.FromQty = updateJobDetailInput.FromQty; + newInput.ToPackingCode = updateJobDetailInput.ToPackingCode; + newInput.ToQty = updateJobDetailInput.ToQty; + newInput.FromLocationCode = transferNoteEditInput.Details[0].FromLocationCode; + newInput.ToLocationCode = transferNoteEditInput.Details[0].ToLocationCode; + var expectOutRet = await _expectOutAppService.SaveDetail_SplitPackingAsync(newInput).ConfigureAwait(false); + var jobRet = await _issueJobAppService.SaveDetail_SplitPackingAsync(updateJobDetailInput).ConfigureAwait(false); + var ret = await SplitPackingAsync(transferNoteEditInput).ConfigureAwait(false); //库存操作 + return ret; + } + + /// + /// 拆箱,预计出表存在数据时不允许办理 + /// + /// + /// + /// + [HttpPost("split-packing-check-expect-out")] + public async Task SplitPackingCheckExpectOutAsync(TransferNoteEditInput transferNoteEditInput, [FromQuery] SplitPacking_UpdateJobDetailInputBase updateJobDetailInputBase) + { + var detailObj = transferNoteEditInput.Details[0]; + SplitPacking_UpdateDetailInput newInput = new SplitPacking_UpdateDetailInput(); + newInput.Number = updateJobDetailInputBase.Number; + newInput.FromPackingCode = detailObj.FromPackingCode; + newInput.FromQty = detailObj.Qty; + newInput.ToPackingCode = detailObj.ToPackingCode; + newInput.ToQty = detailObj.Qty; + newInput.FromLocationCode = detailObj.FromLocationCode; + newInput.ToLocationCode = detailObj.ToLocationCode; + var expectOutLst = await _expectOutAppService.GetListByJobNumberAsync(newInput).ConfigureAwait(false); + if (expectOutLst.Count > 0) + { + throw new UserFriendlyException($"预计出表存在数据,不允许办理拆箱:JobNumber={newInput.Number}|PackingCode={newInput.FromPackingCode}|Qty={newInput.FromQty}|LocationCode={newInput.FromLocationCode}"); + } + var ret = await SplitPackingAsync(transferNoteEditInput).ConfigureAwait(false); + return ret; + + } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAppService.cs index 6053d58d7..74e382612 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Orders/PurchaseOrders/PurchaseOrderAppService.cs @@ -111,14 +111,48 @@ public class PurchaseOrderAppService : input.Number = await _purchaseOrderManager .GenerateNumberAsync(nameof(PurchaseOrder), Clock.Normalize(input.ActiveDate)).ConfigureAwait(false); } - var entity = ObjectMapper.Map(input); entity.Remark = "接口数据"; await _purchaseOrderManager.CreateAsync(entity).ConfigureAwait(false); + return ObjectMapper.Map(entity); } - + /// + /// 采购订单新增和修改(目前修改只支持关闭操作) + /// + /// + /// + [HttpPost("create-or-update")] + public async Task CreateOrUpdateAsync(PurchaseOrderEditInput input) + { + if (string.IsNullOrWhiteSpace(input.Number)) + { + input.Number = await _purchaseOrderManager + .GenerateNumberAsync(nameof(PurchaseOrder), Clock.Normalize(input.ActiveDate)).ConfigureAwait(false); + } + var olditem= await _purchaseOrderManager.GetByNumberAsync(input.Number).ConfigureAwait(false); + var entity = ObjectMapper.Map(input); + if (olditem == null) + { + entity.Remark = "接口数据"; + await _purchaseOrderManager.CreateAsync(entity).ConfigureAwait(false); + } + else + { + olditem.Remark = "接口数据(明细关闭)"; + var closeItemCode= input.Details.Select(r=>r.ItemCode).ToList(); + foreach (var detail in olditem.Details) + { + if (closeItemCode.Contains(detail.ItemCode)) + { + detail.LineStatus = EnumOrderStatus.Close; + } + } + await _purchaseOrderManager.UpdateAsync(olditem).ConfigureAwait(false); + } + return ObjectMapper.Map(entity); + } #region 校验 /// @@ -157,6 +191,7 @@ public class PurchaseOrderAppService : return result; } + #endregion #endregion @@ -304,4 +339,17 @@ public class PurchaseOrderAppService : return dtos; } + /// + /// 获取不存在的订单号 + /// + /// 订单号集合 + /// 返回的是不存在系统中的订单号 + [HttpGet("get-no-po-bill-list")] + public virtual async Task> GetNoPoBillList(List poBillNo) + { + var entitys = await _repository.GetListAsync(p =>poBillNo.Contains(p.Number)).ConfigureAwait(false); + var list = entitys.Select(r => r.Number).ToList(); + list= poBillNo.Except(list).ToList(); + return list; + } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ContainerRequests/ContainerRequestAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ContainerRequests/ContainerRequestAppService.cs new file mode 100644 index 000000000..8bcb88c9f --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ContainerRequests/ContainerRequestAppService.cs @@ -0,0 +1,74 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Threading; +using System.Threading.Tasks; + +using Microsoft.AspNetCore.Authorization; +using Microsoft.AspNetCore.Mvc; +using Microsoft.EntityFrameworkCore; +using Volo.Abp; +using Volo.Abp.Application.Dtos; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Shared.Application.Contracts; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Wms.Inventory.Application.Contracts; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Application; +[Authorize] +[Route($"{StoreConsts.RootPath}container-request")] + +public class ContainerRequestAppService : + SfsStoreRequestAppServiceBase + , + IContainerRequestAppService +{ + private readonly IContainerRequestManager _containerRequestManager; + private readonly IAreaAppService _areaApp; + private readonly ICustomerAppService _customerApp; + private readonly ICustomerAddressAppService _customerAddressApp; + + public ContainerRequestAppService( + IContainerRequestRepository repository + , IContainerRequestManager containerRequestManager + , IAreaAppService areaApp + , ICustomerAppService customerApp + , ICustomerAddressAppService customerAddressApp) + : base(repository, containerRequestManager) + { + _containerRequestManager = containerRequestManager; + _areaApp = areaApp; + _customerApp = customerApp; + _customerAddressApp = customerAddressApp; + } + + + /// + /// 【创建】器具呼叫申请 + /// + /// + /// + [HttpPost("")] + public override async Task CreateAsync(ContainerRequestEditInput input) + { + input.AutoCompleteJob = false; + input.AutoAgree = true; + input.AutoHandle = true; + input.AutoSubmit = true; + input.DirectCreateNote = false; + + var entity = ObjectMapper.Map(input); + + await _containerRequestManager.CreateAsync(entity).ConfigureAwait(false); + + var dto = ObjectMapper.Map(entity); + return dto; + } + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ContainerRequests/ContainerRequestAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ContainerRequests/ContainerRequestAutoMapperProfile.cs new file mode 100644 index 000000000..95c74b2f6 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ContainerRequests/ContainerRequestAutoMapperProfile.cs @@ -0,0 +1,62 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Volo.Abp.Data; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Application; + +using Win_in.Sfs.Shared.Domain.Shared; + +public partial class StoreApplicationAutoMapperProfile : Profile +{ + private void ContainerRequestAutoMapperProfile() + { + CreateMap() + .ReverseMap(); + + CreateMap() + .ReverseMap(); + + CreateMap(); + + CreateMap() + .IgnoreAuditedObjectProperties() + .Ignore(x => x.MasterID) + .Ignore(x => x.TenantId) + .Ignore(x => x.Number) + .Ignore(x => x.Id); + + + CreateMap() + .Ignore(x => x.ActiveDate) + .Ignore(x => x.Details) + .Ignore(x => x.TenantId) + .Ignore(x => x.LastModificationTime) + .Ignore(x => x.LastModifierId) + .Ignore(x => x.CreationTime) + .Ignore(x => x.CreatorId) + .Ignore(x => x.ExtraProperties) + .Ignore(x => x.ConcurrencyStamp) + .Ignore(x => x.Number) + .Ignore(x => x.RequestStatus) + .Ignore(x => x.Remark); + + CreateMap() + .Ignore(x => x.Number) + .Ignore(X => X.StdPackQty) + .Ignore(x => x.Uom) + .Ignore(x => x.ItemName).Ignore(x => x.ItemDesc1).Ignore(x => x.ItemDesc2) + .Ignore(x => x.Remark) + .Ignore(x => x.MasterID) + .Ignore(x => x.LastModificationTime) + .Ignore(x => x.LastModifierId) + .Ignore(x => x.CreationTime) + .Ignore(x => x.CreatorId) + .Ignore(x => x.TenantId) + .Ignore(x => x.Id) + .Ignore(x => x.ExtraProperties) + .Ignore(x => x.Remark); + + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/MaterialRequests/MaterialRequestAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/MaterialRequests/MaterialRequestAppService.cs index f2b653b4c..64d689dbc 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/MaterialRequests/MaterialRequestAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/MaterialRequests/MaterialRequestAppService.cs @@ -199,20 +199,13 @@ public class MaterialRequestAppService : SfsStoreRequestAppServiceBase 0) - { - throw new UserFriendlyException($"{input.PreparationPlanNumber} 备料计划已存在要料申请"); - } - } + input.AutoSubmit = true; input.AutoAgree = true; input.AutoHandle = true; + input.AutoCompleteJob = false; + input.DirectCreateNote = false; foreach (var detailInput in input.Details) { @@ -220,6 +213,23 @@ public class MaterialRequestAppService : SfsStoreRequestAppServiceBase(input); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductRecycleRequests/ProductRecycleRequestAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductRecycleRequests/ProductRecycleRequestAppService.cs index fa3bcbfa7..b008dcd02 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductRecycleRequests/ProductRecycleRequestAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductRecycleRequests/ProductRecycleRequestAppService.cs @@ -21,6 +21,7 @@ using Volo.Abp.Data; using Volo.Abp.Domain.Entities; using Win_in.Sfs.Shared.Application.Contracts; using Win_in.Sfs.Wms.Inventory.Application.Contracts; +using Win_in.Sfs.Wms.Inventory.Domain; /// /// 产品退拆申请 @@ -102,15 +103,16 @@ public class ProductRecycleRequestAppService : foreach (var detail in productRecycleRequest.Details) { - var balance = await _balanceAppService.GetByItemLocationAndPackingAsync( - string.Empty, - detail.ItemCode, - detail.LocationCode).ConfigureAwait(false); + //var balance = await _balanceAppService.GetByItemLocationAndPackingAsync( + // string.Empty, + // detail.ItemCode, + // detail.LocationCode).ConfigureAwait(false); - if (balance != null) - { - detail.Status = balance.Status; - } + //if (balance != null) + //{ + // detail.Status = balance.Status; + //} + detail.Status = EnumInventoryStatus.OK; var locationDto = await _locationAppService.GetByCodeAsync(detail.LocationCode) .ConfigureAwait(false); @@ -188,15 +190,15 @@ public class ProductRecycleRequestAppService : detail.RawLocationGroup = rawLocation.LocationGroupCode; } - var balance = await BalanceAclService.GetByItemLocationAndPackingAsync( - string.Empty, - detail.ItemCode, - detail.LocationCode).ConfigureAwait(false); + //var balance = await BalanceAclService.GetByItemLocationAndPackingAsync( + // string.Empty, + // detail.ItemCode, + // detail.LocationCode).ConfigureAwait(false); - if (balance != null) - { - detail.Status = balance.Status; - } + //if (balance != null) + //{ + // detail.Status = balance.Status; + //} } #endregion diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductRecycleRequests/ProductRecycleRequestAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductRecycleRequests/ProductRecycleRequestAutoMapperProfile.cs index 5f5d91fbe..fc94e67c3 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductRecycleRequests/ProductRecycleRequestAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/ProductRecycleRequests/ProductRecycleRequestAutoMapperProfile.cs @@ -1,5 +1,6 @@ using AutoMapper; using Volo.Abp.AutoMapper; +using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.Store.Application.Contracts; using Win_in.Sfs.Wms.Store.Domain; @@ -25,8 +26,11 @@ public partial class StoreApplicationAutoMapperProfile : Profile CreateMap(); + CreateMap() + .ReverseMap(); + - CreateMap(); + CreateMap() .IgnoreAuditedObjectProperties() @@ -56,5 +60,13 @@ public partial class StoreApplicationAutoMapperProfile : Profile .Ignore(x => x.Number) .Ignore(x => x.Id) .Ignore(x => x.Remark); + + CreateMap() + .ReverseMap(); + + CreateMap() + .ReverseMap(); + + } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReceiptRequests/PurchaseReceiptRequestAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReceiptRequests/PurchaseReceiptRequestAppService.cs index 59210677d..f146614c1 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReceiptRequests/PurchaseReceiptRequestAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReceiptRequests/PurchaseReceiptRequestAppService.cs @@ -4,9 +4,11 @@ using System.Linq; using System.Threading.Tasks; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Mvc; +using Volo.Abp; using Volo.Abp.ObjectMapping; using Volo.Abp.Uow; using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain.Shared; using Win_in.Sfs.Label.Application.Contracts; using Win_in.Sfs.Shared.Domain.Shared; using Win_in.Sfs.Wms.Store.Application.Contracts; @@ -142,4 +144,49 @@ public class PurchaseReceiptRequestAppService : { throw new NotImplementedException(); } + + /// + /// 根据number取列表 + /// + /// + /// + [HttpGet("get-list-by-number")] + public async Task> GetListByNumberAsync(string number) + { + var entity = await _repository.GetListAsync(itm => itm.Number == number).ConfigureAwait(false); + var dto = ObjectMapper.Map, List>(entity); + return dto; + } + + /// + /// 保存拆箱时涉及的明细修改 + /// + /// + /// + /// + [HttpGet("save-detail-split-packing")] + public virtual async Task SaveDetail_SplitPackingAsync(SplitPacking_UpdateJobDetailInput input, string packingCode) + { + var request = await _repository.FindAsync(p => p.Number == packingCode).ConfigureAwait(false); + PurchaseReceiptRequestDetail detail = request.Details.FirstOrDefault(p => p.PackingCode == input.FromPackingCode); /* && p.Qty == input.FromQty*/ + if (detail == null) + { + //throw new UserFriendlyException($"根据PackingCode={input.FromPackingCode}取ReceiptRequestDetail表为空!"); + throw new UserFriendlyException($"根据PackingCode={input.FromPackingCode}取PurchaseReceiptRequestDetail表为空!"); + } + //插入目标箱 + var newDetail = CommonHelper.CloneObj(detail); + newDetail.SetId(GuidGenerator.Create()); + newDetail.PackingCode = input.ToPackingCode; + newDetail.Qty = input.ToQty; + //newDetail.CreationTime = CommonHelper.CurTime; + request.Details.Add(newDetail); + //修改源箱 + detail.Qty = input.FromQty - input.ToQty; + var entity = await _repository.UpdateAsync(request).ConfigureAwait(false); + var ret = ObjectMapper.Map(entity); + return ret; + } + + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReturnRequests/PurchaseReturnRequestAppService.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReturnRequests/PurchaseReturnRequestAppService.cs index 4632ad53d..4b033f9bc 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReturnRequests/PurchaseReturnRequestAppService.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReturnRequests/PurchaseReturnRequestAppService.cs @@ -9,6 +9,7 @@ using Microsoft.AspNetCore.Mvc; using Microsoft.EntityFrameworkCore; using Volo.Abp; using Volo.Abp.Domain.Entities; +using Volo.Abp.ObjectMapping; using Win_in.Sfs.Basedata.Application.Contracts; using Win_in.Sfs.Label.Application.Contracts; using Win_in.Sfs.Label.Domain; @@ -77,6 +78,24 @@ public class PurchaseReturnRequestAppService : return dto; } + /// + /// 【创建】采购退货申请(批量) + /// + /// + /// + [HttpPost("create-many")] + public async Task> CreateManyAsync(List inputs) + { + var entitys = ObjectMapper.Map< List, List< PurchaseReturnRequest> >(inputs); + + await _purchaseReturnRequestManager.CreateManyAsync(entitys).ConfigureAwait(false); + + var dto = ObjectMapper.Map< List, List< PurchaseReturnRequestDTO> >(entitys); + return dto; + } + + + [HttpPost("check-status")] public virtual async Task CheckStatusAsync(string number) { diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReturnRequests/PurchaseReturnRequestAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReturnRequests/PurchaseReturnRequestAutoMapperProfile.cs index 52ac6afb3..75841ab08 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReturnRequests/PurchaseReturnRequestAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Requests/PurchaseReturnRequests/PurchaseReturnRequestAutoMapperProfile.cs @@ -20,7 +20,7 @@ public partial class StoreApplicationAutoMapperProfile : Profile .Ignore(x => x.TenantId) .Ignore(x => x.Number) .Ignore(x => x.Id); - + CreateMap(); CreateMap() .Ignore(x => x.ReturnType) .Ignore(x => x.ReturnTime) diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/StoreApplicationAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/StoreApplicationAutoMapperProfile.cs index 8dfb70eb6..7fa33e59e 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/StoreApplicationAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/StoreApplicationAutoMapperProfile.cs @@ -10,6 +10,7 @@ public partial class StoreApplicationAutoMapperProfile : Profile PurchaseReceiptRequestAutoMapperProfile(); DeliverRequestAutoMapperProfile(); + ContainerRequestAutoMapperProfile(); InspectRequestAutoMapperProfile(); ItemTransformRequestAutoMapperProfile(); MaterialRequestAutoMapperProfile(); @@ -59,6 +60,7 @@ public partial class StoreApplicationAutoMapperProfile : Profile InventoryTransferNoteMapperProfile(); IsolationNoteAutoMapperProfile(); IssueNoteAutoMapperProfile(); + ContainerNoteAutoMapperProfile(); ItemTransformNoteAutoMapperProfile(); JisDeliverNoteAutoMapperProfile(); JisProductReceiptNoteAutoMapperProfile(); @@ -90,8 +92,10 @@ public partial class StoreApplicationAutoMapperProfile : Profile DeliverJobAutoMapperProfile(); InspectJobAutoMapperProfile(); IssueJobAutoMapperProfile(); + ContainerJobAutoMapperProfile(); JisDeliverJobAutoMapperProfile(); ProductReceiveJobAutoMapperProfile(); + ProductRecycleJobAutoMapperProfile(); PurchaseReceiptJobAutoMapperProfile(); PurchaseReturnJobAutoMapperProfile(); PutawayJobAutoMapperProfile(); @@ -104,6 +108,7 @@ public partial class StoreApplicationAutoMapperProfile : Profile #endregion ExchangeDataAutoMapperProfile(); + EquipmentRecordAutoMapperProfile(); } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Win_in.Sfs.Wms.Store.Application.csproj b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Win_in.Sfs.Wms.Store.Application.csproj index 8baf5221b..314d76f6d 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Win_in.Sfs.Wms.Store.Application.csproj +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Application/Win_in.Sfs.Wms.Store.Application.csproj @@ -29,9 +29,7 @@ - - diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain.Shared/Win_in.Sfs.Wms.Store.Domain.Shared.csproj b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain.Shared/Win_in.Sfs.Wms.Store.Domain.Shared.csproj index 27404e1b6..e21cbe9a6 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain.Shared/Win_in.Sfs.Wms.Store.Domain.Shared.csproj +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain.Shared/Win_in.Sfs.Wms.Store.Domain.Shared.csproj @@ -1,4 +1,4 @@ - + @@ -9,6 +9,7 @@ + diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/EquipmentRecord.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/EquipmentRecord.cs new file mode 100644 index 000000000..1fed8946a --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/EquipmentRecord.cs @@ -0,0 +1,58 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared.Enums.Store.Statuses; + +namespace Win_in.Sfs.Wms.Store.Equipments; + +/// +/// 器具绑定解绑记录 +/// +public class EquipmentRecord:SfsAggregateRootBase +{ + /// + /// 器具编码 + /// + public string EqptCode { get; set; } + /// + /// 条码编号 + /// + public string BarCode { get; set; } + /// + /// 零件号 + /// + public string PartCode { get; set; } + /// + /// 批次 + /// + public string Batch { get; set; } + /// + /// 来源库位 + /// + public string FromLocCode { get; set; } + + /// + /// 目标库位 + /// + public string ToLocCode { get; set; } + + /// + /// 数量 + /// + public decimal Qty { get; set; } + /// + /// 状态 + /// + public int State { get; set; } + /// + /// 记录类型 + /// + public EnumEquipmentRecordType Type { get; set;} + + + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/EquipmentRecordDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/EquipmentRecordDetail.cs new file mode 100644 index 000000000..61a8ce19f --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/EquipmentRecordDetail.cs @@ -0,0 +1,112 @@ +using System; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public class EquipmentRecordDetail : SfsStoreDetailWithQtyEntityBase +//, IHasSupplierPack +{ + ///// + ///// 订单行 + ///// + //public string PoLine { get; set; } + + ///// + ///// 供应商计量单位 + ///// + //public string SupplierPackUom { get; set; } + + ///// + ///// 供应商计量单位 + ///// + //public decimal SupplierPackQty { get; set; } + + ///// + ///// 转换率 + ///// + //public decimal ConvertRate { get; set; } + + ///// + ///// 是否寄存订单 + ///// + //public bool IsConsignment { get; set; } + + ///// + ///// 订单行状态 0:无效1:有效 + ///// + //public EnumOrderStatus LineStatus { get; set; } + + ///// + ///// ERP库位 + ///// + //public string LocationErpCode { get; set; } + + ///// + ///// 项目编号 + ///// + //public string ProjectCode { get; set; } + + ///// + ///// 已发货数量 + ///// + //public decimal ShippedQty { get; set; } + + ///// + ///// 已收货数量 + ///// + //public decimal ReceivedQty { get; set; } + + ///// + ///// 已退货数量 + ///// + //public decimal ReturnedQty { get; set; } + + ///// + ///// 已上架数量 + ///// + //public decimal PutAwayQty { get; set; } + + ///// + ///// 筹措员代码 + ///// + //[Display(Name = "明细-筹措员代码")] + //public string PlanUserCode { get; set; } + + ///// + ///// 生产批次 + ///// + //[Display(Name = "明细-生产批次")] + //public string Lot { get; set; } + + ///// + ///// 要求到货时间 + ///// + //[Display(Name = "明细-要求到货时间")] + //public DateTime PlanArriveDate { get; set; } + + ///// + ///// 明细-类型 暂定:备件是B 辅材是F 生产为空 + ///// + //[Display(Name = "明细-类型")] + //public string Ctype { get; set; } + + ///// + ///// 生产时间 + ///// + //[Display(Name = "明细-生产时间")] + //public DateTime ProduceDate { get; set; } + + ///// + ///// 过期时间 + ///// + //[Display(Name = "明细-过期时间")] + //public DateTime ExpireDate { get; set; } + + ///// + ///// 订单备注 + ///// + //[Display(Name = "明细-订单备注")] + //public string OrderRemark { get; set; } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/EquipmentRecordManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/EquipmentRecordManager.cs new file mode 100644 index 000000000..cf4486906 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/EquipmentRecordManager.cs @@ -0,0 +1,226 @@ +using System; +using System.Collections.Generic; + +using System.Linq; +using System.Threading.Tasks; +using DocumentFormat.OpenXml.Packaging; +using Volo.Abp.Domain.Services; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Basedata.Domain.Shared; +using Win_in.Sfs.Basedata.Equipments.DTOs; +using Win_in.Sfs.Shared.Domain.Shared.Enums.Store.Statuses; +using Win_in.Sfs.Wms.Store.Equipments; + +namespace Win_in.Sfs.Wms.Store.Domain; + + + + +public class EquipmentRecordManager : DomainService, IEquipmentRecordManager +{ + private readonly IEquipmentRecordRepository _repository; + // private readonly IEquipmentLocCapRepository _repositoryCap; + + private readonly IEquipmentLocAppService _locService; + private readonly IEquipmentPartCodeAppService _partService; + + public EquipmentRecordManager( + IEquipmentRecordRepository repository, + //IEquipmentLocCapRepository repositoryCap, + IEquipmentLocAppService locService, + IEquipmentPartCodeAppService partService + ) + { + _locService=locService; + _repository = repository; + // _repositoryCap = repositoryCap; + _partService= partService; + } + + public async Task> Bind(List p_ls) + { + List errors=new List(); + // var list= p_ls.GroupBy(p => new { p.EqptCode, p.PartCode }).Select(p=>new { EqptCode= p.Key.EqptCode, PartCode= p.Key.PartCode,SumQty=p.Sum(p=>p.Qty)});//导入零件 + // var partialErrors1=list.GroupBy(p => p.EqptCode).Where(g =>g.Count()>1).Select(p => new EquipmentRecordErrorDTO() { EqptCode= p.Key,PartCode=string.Empty,Error=$"同器具代码有{p.Count().ToString()}种零件!" }); + // errors.AddRange(partialErrors1.ToList());//同容器放不同零件校验 + // var ls=p_ls.Select(p => p.EqptCode).Distinct().ToList();//录入的器具记录代码列表 + // var Locs=_locService.GetEquipmentLocAsync(ls).Result;//获取器具库位关系 + // var parts =_partService.GetEquipmentPartCodesAsync(ls).Result;//获取器具零件关系 + // //零件和器具关系校验 + // var partErrorQery = from itm in list + // join itm1 in parts on + // new { itm.EqptCode, PartCode = itm.PartCode } equals new { EqptCode = itm1.Code, PartCode = itm1.PartCode } + // into temp + // from tm in temp.DefaultIfEmpty() + // where tm == null + // select new EquipmentRecordErrorDTO() + // { + // EqptCode = itm.EqptCode, + // PartCode = itm.PartCode, + // Error = $"器具零件关系不存在!" + // }; + // errors.AddRange(partErrorQery.ToList()); + // var query= await _repositoryCap.GetQueryableAsync().ConfigureAwait(false); + // var capExistList= query.Where(p => ls.Contains(p.EqptCode)).ToList();//器具容量 + + // var partialErrors2 = from itm in capExistList + // join itm1 in list.ToList() on itm.EqptCode equals itm1.EqptCode + // where itm.PartCode != itm.PartCode + // select new EquipmentRecordErrorDTO() { + // EqptCode = itm.EqptCode,PartCode=itm.PartCode ,Error=$"录入器具代码{itm.EqptCode}零件代码{itm.PartCode}与器具容量{itm1.EqptCode}零件代码{itm1.PartCode}不符!" + // }; + // errors.AddRange(partialErrors2.ToList());//导入记录和容量记录零件不是同一零件 + // var existList = from itm in list + // join itm1 in capExistList + // on new { itm.EqptCode, itm.PartCode } equals new { itm1.EqptCode, itm1.PartCode } + // select itm; + // foreach (var itm in existList) + // { + // var cap = capExistList.FirstOrDefault(p => p.EqptCode == itm.EqptCode && p.PartCode == itm.PartCode);//读取当前器具容量 + // cap.Qty += itm.SumQty;//当前数量 + + // if (cap.Qty > cap.StdQty) + // { + // errors.Add(new EquipmentRecordErrorDTO() { EqptCode=itm.EqptCode,PartCode=itm.PartCode,Error=$"超出容量限制!" }); + // } + // } + + // if (errors.Count > 0) + // { + // return errors; + // } + // //新建器具容量 + //var newList =from itm in list + // join itm1 in capExistList + // on new { itm.EqptCode, itm.PartCode } equals new { itm1.EqptCode, itm1.PartCode } + // into temp1 + // from tm1 in temp1.DefaultIfEmpty() + // where tm1 == null + // select itm; + // List newlocList=new List(); + // foreach (var itm in newList) + // { + // var gpart = parts.FirstOrDefault(p => p.Code == itm.EqptCode && p.PartCode == itm.PartCode); + // var stdQty = gpart.StdQty;//标包 + // var qty = itm.SumQty; + // var cap = new EquipmentLocCap() + + // { + // EqptCode=itm.EqptCode, + // PartCode=itm.PartCode, + // Percent=qty/stdQty, + // Qty=qty, + // StdQty=stdQty, + // }; + // cap.SetId(GuidGenerator.Create()); + // newlocList.Add(cap); + // } + // //已存在器具容量变更 + + // foreach (var itm in existList) + // { + // var cap = capExistList.FirstOrDefault(p => p.EqptCode == itm.EqptCode && p.PartCode == itm.PartCode);//读取当前器具容量 + // cap.Qty = cap.Qty+itm.SumQty;//当前数量 + // cap.Percent = cap.Qty / cap.StdQty; + // } + + // foreach (var itm in p_ls) + // { + // itm.Type = EnumEquipmentRecordType.Bind; + // itm.SetId(GuidGenerator.Create()); + // } + // await _repositoryCap.InsertManyAsync(newlocList).ConfigureAwait(false); + // await _repository.InsertManyAsync(p_ls).ConfigureAwait(false); + + + return errors; + + } + + + + + public async Task> UnBind(List p_ls) + { + List errors = new List(); + //var list = p_ls.GroupBy(p => new { p.EqptCode, p.PartCode }).Select(p => new { EqptCode = p.Key.EqptCode, PartCode = p.Key.PartCode, SumQty = p.Sum(p => p.Qty) });//导入零件 + //var partialErrors1 = list.GroupBy(p => p.EqptCode).Where(g => g.Count() > 1).Select(p => new EquipmentRecordErrorDTO() { EqptCode = p.Key, PartCode = string.Empty, Error = $"同器具代码有{p.Count().ToString()}种零件!" }); + //errors.AddRange(partialErrors1.ToList());//同容器放不同零件校验 + //var ls = p_ls.Select(p => p.EqptCode).Distinct().ToList();//录入的器具记录代码列表 + //var Locs = _locService.GetEquipmentLocAsync(ls).Result;//获取器具库位关系 + //var parts = _partService.GetEquipmentPartCodesAsync(ls).Result;//获取器具零件关系 + ////零件和器具关系校验 + //var partErrorQery = from itm in list + // join itm1 in parts on + // new { itm.EqptCode, PartCode = itm.PartCode } equals new { EqptCode = itm1.Code, PartCode = itm1.PartCode } + // into temp + // from tm in temp.DefaultIfEmpty() + // where tm == null + // select new EquipmentRecordErrorDTO() + // { + // EqptCode = itm.EqptCode, + // PartCode = itm.PartCode, + // Error = $"器具零件关系不存在!" + // }; + //errors.AddRange(partErrorQery.ToList()); + //var query = await _repositoryCap.GetQueryableAsync().ConfigureAwait(false); + //var capExistList = query.Where(p => ls.Contains(p.EqptCode)).ToList();//器具容量 + + //var partialErrors2 = from itm in capExistList + // join itm1 in list.ToList() on itm.EqptCode equals itm1.EqptCode + // where itm.PartCode != itm.PartCode + // select new EquipmentRecordErrorDTO() + // { + // EqptCode = itm.EqptCode, + // PartCode = itm.PartCode, + // Error = $"录入器具代码{itm.EqptCode}零件代码{itm.PartCode}与器具容量{itm1.EqptCode}零件代码{itm1.PartCode}不符!" + // }; + //errors.AddRange(partialErrors2.ToList());//导入记录和器具容量记录零件不是同一零件 + //var existList = from itm in list + // join itm1 in capExistList + // on new { itm.EqptCode, itm.PartCode } equals new { itm1.EqptCode, itm1.PartCode } + // select itm; + //foreach (var itm in existList) + //{ + // var cap = capExistList.FirstOrDefault(p => p.EqptCode == itm.EqptCode && p.PartCode == itm.PartCode);//读取当前器具容量 + // cap.Qty =cap.Qty- itm.SumQty;//当前数量 + + // if (cap.Qty <0) + // { + // errors.Add(new EquipmentRecordErrorDTO() { EqptCode = itm.EqptCode, PartCode = itm.PartCode, Error = $"解绑数量小0!" }); + // } + //} + + //foreach (var itm in existList) + //{ + // var cap = capExistList.FirstOrDefault(p => p.EqptCode == itm.EqptCode && p.PartCode == itm.PartCode);//读取当前器具容量 + // cap.Qty = cap.Qty - itm.SumQty;//当前数量 + // cap.Percent = cap.Qty / cap.StdQty; + //} + + //foreach (var itm in p_ls) + //{ + // itm.Type = EnumEquipmentRecordType.UnBind; + // itm.SetId(GuidGenerator.Create()); + //} + + //await _repository.InsertManyAsync(p_ls).ConfigureAwait(false); + + + + + + + return errors; + + } + public Task ImportDataAsync(List entities, List deleteEntities = null) + { + throw new NotImplementedException(); + } + + private async Task SetDetailAsync(List details) + { + + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/IEquipmentRecordManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/IEquipmentRecordManager.cs new file mode 100644 index 000000000..4b22f2e05 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/IEquipmentRecordManager.cs @@ -0,0 +1,16 @@ +using System; +using System.Collections.Generic; +using System.Threading.Tasks; +using Win_in.Sfs.Basedata.Equipments.DTOs; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Wms.Store.Equipments; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public interface IEquipmentRecordManager : IBulkImportService +{ + Task> Bind(List p_ls); + Task> UnBind(List p_ls); + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/IEquipmentRecordRepository.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/IEquipmentRecordRepository.cs new file mode 100644 index 000000000..07d9b3e91 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Equipments/IEquipmentRecordRepository.cs @@ -0,0 +1,10 @@ +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Wms.Store.Equipments; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public interface IEquipmentRecordRepository : ISfsStoreRepositoryBase, ISfsBulkRepositoryBase +{ + Task UpsertAsync(EquipmentRecord newData); +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerExtension.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerExtension.cs new file mode 100644 index 000000000..6c22704f6 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerExtension.cs @@ -0,0 +1,39 @@ +using Volo.Abp.Timing; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public static class ContainerExtension +{ + + + public static ContainerJob Init(this ContainerJob job) + { + job.JobType = EnumJobType.IssueJob; + job.JobStatus = EnumJobStatus.Open; + return job; + } + + public static ContainerJob SetWorkGroup(this ContainerJob job, string warehouseCode, string workGroupCode, string groupCode) + { + job.WorkGroupCode = workGroupCode; + job.WarehouseCode = warehouseCode; + return job; + } + + public static ContainerJob SetWorker(this ContainerJob job, string worker) + { + job.Worker = worker; + return job; + } + + public static ContainerJob SetPriority(this ContainerJob job, IClock clock) + { + job.Priority = PriorityHelper.GetPriority(clock); + job.PriorityIncrement = 1; + return job; + } + + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerJob.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerJob.cs new file mode 100644 index 000000000..99e95973c --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerJob.cs @@ -0,0 +1,78 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Domain; + +/// +/// 器具呼叫任务 +/// +[Display(Name = "器具呼叫任务")] +public class ContainerJob : SfsJobAggregateRootBase +{ + /// + /// 器具呼叫号码 + /// + [IgnoreUpdate] + public string ContainerRequestNumber { get; set; } + + /// + /// 呼叫库位代码 + /// + [IgnoreUpdate] + public string RequestLocationCode { get; set; } + + /// + /// 器具类型 + /// + [IgnoreUpdate] + public string ContainerType { get; set; } + + /// + /// 器具规格 + /// + [IgnoreUpdate] + public string SpecificationsType { get; set; } + + /// + /// 任务明细 + /// + [IgnoreUpdate] + public override List Details { get; set; } = new List(); + + /// + /// 设置任务明细的实际库位和实际数量 + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + public virtual async Task BuildDetail(Guid id, string handledLocationCode, string handledLocationErpCode, + string handledWarehouseCode, decimal handledQty, string handledSupplierBatch, DateTime handledArriveDate, DateTime handledProduceDate, DateTime handledExpireDate, + string handledContainerCode, string handledLot, string handledPackingCode) + { + var detail = GetDetail(id); + detail.HandledFromLocationCode = handledLocationCode; + detail.HandledFromLocationErpCode = handledLocationErpCode; + detail.HandledFromWarehouseCode = handledWarehouseCode; + detail.HandledQty = handledQty; + detail.HandledSupplierBatch = handledSupplierBatch; + detail.HandledArriveDate = handledArriveDate; + detail.HandledProduceDate = handledProduceDate; + detail.HandledExpireDate = handledExpireDate; + detail.HandledContainerCode = handledContainerCode; + detail.HandledLot = handledLot; + detail.HandledPackingCode = handledPackingCode; + await Task.CompletedTask.ConfigureAwait(false); + } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerJobDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerJobDetail.cs new file mode 100644 index 000000000..725085817 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerJobDetail.cs @@ -0,0 +1,26 @@ +using System; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public class ContainerJobDetail : SfsJobRecommendFromDetailEntityBase +{ + /// + /// 呼叫库位代码 + /// + + public string ToLocationCode { get; set; } + + /// + /// 来源库位代码 + /// + + public string FromLocationCode { get; set; } + + public void SetId(Guid id) + { + this.Id = id; + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerJobManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerJobManager.cs new file mode 100644 index 000000000..291fbb30e --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/ContainerJobManager.cs @@ -0,0 +1,83 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Linq.Expressions; +using System.Threading.Tasks; +using Volo.Abp.Users; +using Volo.Abp.Validation; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public class ContainerJobManager : SfsJobManagerBase, IContainerJobManager +{ + + public ContainerJobManager( + IContainerJobRepository repository + ) : base(repository) + { + } + + /// + /// 执行任务 + /// + /// + /// + /// + /// + public override async Task CompleteAsync(ContainerJob input, ICurrentUser user) + { + var entity = await Repository.FindAsync(input.Id).ConfigureAwait(false); + + foreach (var detail in input.Details) + { + //发料子任务 赋值实际转移 + await entity.BuildDetail(detail.Id, + detail.HandledFromLocationCode, + detail.HandledFromLocationErpCode, + detail.HandledFromWarehouseCode, + detail.HandledQty, + detail.HandledSupplierBatch, + detail.HandledArriveDate, + detail.HandledProduceDate, + detail.HandledExpireDate, + detail.HandledContainerCode, + detail.HandledLot, + detail.HandledPackingCode).ConfigureAwait(false); + } + + return await base.CompleteAsync(entity, user).ConfigureAwait(false); + } + + public override void CheckDetails(ContainerJob entity, AbpValidationResult result) + { + var details = entity.Details; + foreach (var detail in details) + { + if (detail.HandledFromLocationCode == null) + { + result.Errors.Add(new ValidationResult($"{detail.HandledFromLocationCode} 不能为空")); + } + + } + } + + public override async Task> GetWorkingListByPackingAsync(string packingCode) + { + return await Repository.GetListAsync(c => c.Details.Any(p => p.RecommendPackingCode == packingCode) && c.JobStatus != EnumJobStatus.Closed && c.JobStatus != EnumJobStatus.Cancelled, true).ConfigureAwait(false); + + } + + public override async Task> GetWorkingListByContainerAsync(string containerCode) + { + return await Repository.GetListAsync(c => c.Details.Any(p => p.RecommendContainerCode == containerCode) && c.JobStatus != EnumJobStatus.Closed && c.JobStatus != EnumJobStatus.Cancelled, true).ConfigureAwait(false); + + } + + + public async Task GetAsync(Expression> expression) + { + return await Repository.FindAsync(expression).ConfigureAwait(false); + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/IContainerJobManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/IContainerJobManager.cs new file mode 100644 index 000000000..e642f7997 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/IContainerJobManager.cs @@ -0,0 +1,10 @@ +using System; +using System.Linq.Expressions; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public interface IContainerJobManager : IJobManager +{ + Task GetAsync(Expression> expression); +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/IContainerJobRepository.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/IContainerJobRepository.cs new file mode 100644 index 000000000..935601bee --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ContainerJobs/IContainerJobRepository.cs @@ -0,0 +1,6 @@ +namespace Win_in.Sfs.Wms.Store.Domain; + +public interface IContainerJobRepository : ISfsJobRepositoryBase +{ + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/InspectJobs/InspectJob.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/InspectJobs/InspectJob.cs index 8e4165387..4f5a09fad 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/InspectJobs/InspectJob.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/InspectJobs/InspectJob.cs @@ -144,4 +144,5 @@ public class InspectJob : SfsJobAggregateRootBase { Number = number; } + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/InspectJobs/InspectJobDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/InspectJobs/InspectJobDetail.cs index 07b445d27..85d50803d 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/InspectJobs/InspectJobDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/InspectJobs/InspectJobDetail.cs @@ -1,3 +1,4 @@ +using System; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using Win_in.Sfs.Shared.Domain; @@ -115,4 +116,10 @@ public class InspectJobDetail : SfsJobDetailEntityBase /// [Display(Name = "其他属性Json")] public string OtherPropertyJson { get; set; } + + public virtual void SetId(Guid id) + { + this.Id = id; + } + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/IssueJobs/IssueJobDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/IssueJobs/IssueJobDetail.cs index 7f3fa9aa5..160e7d6f3 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/IssueJobs/IssueJobDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/IssueJobs/IssueJobDetail.cs @@ -90,4 +90,19 @@ public class IssueJobDetail : SfsJobRecommendFromDetailEntityBase, IHasToLocatio /// 每次配送数量 /// public decimal DeliveryQty { get; set; } + + /// + /// 位置码 + /// + public string PositionCode { get; set; } + + /// + /// 推荐类型 + /// + public EnumRecommendType RecommendType { get; set; } + + public void SetId(Guid id) + { + this.Id = id; + } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/IProductRecycleJobManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/IProductRecycleJobManager.cs new file mode 100644 index 000000000..1efc5bb08 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/IProductRecycleJobManager.cs @@ -0,0 +1,10 @@ +using System; +using System.Linq.Expressions; +using System.Threading.Tasks; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public interface IProductRecycleJobManager : IJobManager +{ + Task GetAsync(Expression> expression); +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/IProductRecycleJobRepository.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/IProductRecycleJobRepository.cs new file mode 100644 index 000000000..3aeb5085e --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/IProductRecycleJobRepository.cs @@ -0,0 +1,6 @@ +namespace Win_in.Sfs.Wms.Store.Domain; + +public interface IProductRecycleJobRepository : ISfsJobRepositoryBase +{ + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleExtension.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleExtension.cs new file mode 100644 index 000000000..d57cac32a --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleExtension.cs @@ -0,0 +1,21 @@ +using Volo.Abp.Timing; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public static class ProductRecycleExtension +{ + public static ProductRecycleJob SetWorkGroup(this ProductRecycleJob job, string warehouseCode, string workGroupCode) + { + job.WorkGroupCode = workGroupCode; + job.WarehouseCode = warehouseCode; + return job; + } + + public static ProductRecycleJob SetPriority(this ProductRecycleJob job, IClock clock) + { + job.Priority = PriorityHelper.GetPriority(clock); + job.PriorityIncrement = 1; + return job; + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleJob.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleJob.cs new file mode 100644 index 000000000..99c3ebc7c --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleJob.cs @@ -0,0 +1,66 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Threading.Tasks; +using Win_in.Sfs.Shared.Domain.Entities; + +namespace Win_in.Sfs.Wms.Store.Domain; + +/// +/// 产品退拆任务 +/// +[Display(Name = "产品退拆任务")] +public class ProductRecycleJob : SfsJobAggregateRootBase +{ + /// + /// 车间 + /// + [Display(Name = "车间")] + public string Workshop { get; set; } + + /// + /// 班次 + /// + [Display(Name = "班次")] + public string Shift { get; set; } + + /// + /// 明细列表 + /// + [IgnoreUpdate] + public override List Details { get; set; } = new List(); + + /// + /// 设置任务明细的实际库位和实际数量 + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + /// + public virtual async Task SetDetail(Guid id, string handledLocationCode, string handledLocationErpCode, string handledWarehouseCode, decimal handledQty, string handledSupplierBatch, DateTime handledArriveDate, DateTime handledProduceDate, DateTime handledExpireDate + , string handledContainerCode, string handledLot, string handledPackingCode) + { + var detail = GetDetail(id); + detail.HandledToLocationCode = handledLocationCode; + detail.HandledToLocationErpCode = handledLocationErpCode; + detail.HandledToWarehouseCode = handledWarehouseCode; + detail.HandledQty = handledQty; + detail.HandledSupplierBatch = handledSupplierBatch; + detail.HandledArriveDate = handledArriveDate; + detail.HandledProduceDate = handledProduceDate; + detail.HandledExpireDate = handledExpireDate; + detail.HandledContainerCode = handledContainerCode; + detail.HandledLot = handledLot; + detail.HandledPackingCode = handledPackingCode; + await Task.CompletedTask.ConfigureAwait(false); + } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleJobDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleJobDetail.cs new file mode 100644 index 000000000..b8d8827f6 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleJobDetail.cs @@ -0,0 +1,88 @@ +using System.ComponentModel.DataAnnotations.Schema; +using System.ComponentModel.DataAnnotations; +using Volo.Abp.Data; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public class ProductRecycleJobDetail : SfsJobRecommendToDetailEntityBase +{ + /// + /// Bom版本 + /// + public string BomVersion { get; set; } + + /// + /// 库位代码 + /// + public string LocationCode { get; set; } + + /// + /// 库区 + /// + public string LocationArea { get; set; } + + /// + /// 库位组 + /// + public string LocationGroup { get; set; } + + /// + /// ERP库位代码 + /// + public string LocationErpCode { get; set; } + + /// + /// 原料库位代码 + /// + public string RawLocationCode { get; set; } + + /// + /// 原料库区 + /// + public string RawLocationArea { get; set; } + + /// + /// 原料库位组 + /// + public string RawLocationGroup { get; set; } + + /// + /// 原料ERP库位 + /// + public string RawLocationErpCode { get; set; } + + /// + /// 原料仓库 + /// + public string RawWarehouseCode { get; set; } + + /// + /// 计量单位 + /// + [Display(Name = "计量单位")] + [MaxLength(SfsPropertyConst.CodeLength)] + public string Uom { get; set; } + + /// + /// 数量 + /// + [Display(Name = "数量")] + [Column(TypeName = "decimal(18,6)")] + public decimal Qty { get; set; } + + /// + /// 扩展属性 + /// + public ExtraPropertyDictionary ExtraProperties { get; } = new ExtraPropertyDictionary(); + + /// + /// 库存状态 + /// + public EnumInventoryStatus Status { get; set; } + + /// + /// 仓库代码 + /// + public string WarehouseCode { get; set; } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleJobManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleJobManager.cs new file mode 100644 index 000000000..f27a29a7c --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/ProductRecycleJobs/ProductRecycleJobManager.cs @@ -0,0 +1,61 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.Linq; +using System.Linq.Expressions; +using System.Threading.Tasks; +using Volo.Abp.Domain.Repositories; +using Volo.Abp.Users; +using Volo.Abp.Validation; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public class ProductRecycleJobManager : SfsJobManagerBase, IProductRecycleJobManager +{ + + public ProductRecycleJobManager( + IProductRecycleJobRepository repository + ) : base(repository) + { + } + + public override void CheckDetails(ProductRecycleJob entity, AbpValidationResult result) + { + var details = entity.Details; + foreach (var detail in details) + { + if (detail.HandledToLocationCode == null) + { + result.Errors.Add(new ValidationResult($"{detail.HandledToLocationCode} 不能为空")); + } + + } + } + + public override async Task> GetWorkingListByPackingAsync(string packingCode) + { + return await Repository.GetListAsync( + c => c.Details.Any(p => p.RecommendPackingCode == packingCode) + && c.JobStatus != EnumJobStatus.Closed + && c.JobStatus != EnumJobStatus.Cancelled + , true).ConfigureAwait(false); + + } + + public override async Task> GetWorkingListByContainerAsync(string containerCode) + { + return await Repository.GetListAsync( + c => c.Details.Any(p => p.RecommendContainerCode == containerCode) + && c.JobStatus != EnumJobStatus.Closed + && c.JobStatus != EnumJobStatus.Cancelled + , true).ConfigureAwait(false); + + } + + public async Task GetAsync(Expression> expression) + { + return await Repository.FindAsync(expression).ConfigureAwait(false); + } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/IPurchaseReceiptJobManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/IPurchaseReceiptJobManager.cs index 5976b0943..914b42d92 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/IPurchaseReceiptJobManager.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/IPurchaseReceiptJobManager.cs @@ -1,5 +1,9 @@ +using System.Collections.Generic; +using System.Threading.Tasks; + namespace Win_in.Sfs.Wms.Store.Domain; public interface IPurchaseReceiptJobManager : IJobManager { + Task> GetListByNumberAsync(string number); } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobDetail.cs index 7ffb4d379..fb1d28694 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobDetail.cs @@ -59,4 +59,11 @@ public class PurchaseReceiptJobDetail : SfsJobRecommendToDetailEntityBase, IHasP [Display(Name = "供应商包装")] public decimal SupplierPackQty { get; set; } + public void SetId(Guid id) + { + this.Id = id; + } + + + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobManager.cs index 11d85fc8d..f87404a63 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobManager.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Jobs/PurchaseReceiptJobs/PurchaseReceiptJobManager.cs @@ -110,4 +110,16 @@ public class PurchaseReceiptJobManager : SfsJobManagerBase c.Details.Any(p => p.RecommendPackingCode == packingCode) && c.JobStatus != EnumJobStatus.Closed && c.JobStatus != EnumJobStatus.Cancelled, true).ConfigureAwait(false); } + + /// + /// 根据number取列表 + /// + /// + /// + public async Task> GetListByNumberAsync(string number) + { + var result = await Repository.GetListAsync(c => c.Number == number).ConfigureAwait(false); + return result; + } + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/ContainerNote.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/ContainerNote.cs new file mode 100644 index 000000000..79edc854b --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/ContainerNote.cs @@ -0,0 +1,81 @@ +using System; +using System.Collections.Generic; +using DocumentFormat.OpenXml.Wordprocessing; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; +using Volo.Abp; + +namespace Win_in.Sfs.Wms.Store.Domain; + +/// +/// 器具呼叫记录 +/// +public class ContainerNote : SfsStoreAggregateRootBase, IHasJobNumber +{ + /// + /// 任务ID + /// + [IgnoreUpdate] + public string JobNumber { get; set; } + + /// + /// 器具申请号码 + /// + [Display(Name = "器具申请号码")] + public string ContainerRequestNumber { get; set; } + + /// + /// 呼叫库位代码 + /// + [IgnoreUpdate] + public string RequestLocationCode { get; set; } + + /// + /// 器具类型 + /// + [IgnoreUpdate] + public string ContainerType { get; set; } + + /// + /// 器具规格 + /// + [IgnoreUpdate] + public string SpecificationsType { get; set; } + + /// + /// 已确认 + /// + [Display(Name = "已确认")] + public bool Confirmed { get; set; } + + /// + /// 确认时间 + /// + [Display(Name = "确认时间")] + public DateTime? ConfirmTime { get; set; } + + /// + /// 任务明细 + /// + [IgnoreUpdate] + public override List Details { get; set; } = new(); + + public void Confirm(DateTime confirmTime) + { + + CheckStatus(Confirmed); + Confirmed = true; + ConfirmTime = confirmTime; + } + + private static void CheckStatus(bool confirmed) + { + if (confirmed) + { + throw new UserFriendlyException($"当前状态为 【已确认】 ,无法再次确认!"); + } + + } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/ContainerNoteDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/ContainerNoteDetail.cs new file mode 100644 index 000000000..0958ea881 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/ContainerNoteDetail.cs @@ -0,0 +1,16 @@ +using Volo.Abp.Data; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public class ContainerNoteDetail : SfsStoreRecommendFromDetailWithFromToEntityBase, IHasExtraProperties +{ + /// + /// 呼叫库位 + /// + public string ToLocationCode { get; set; } + + /// + /// 扩展属性 + /// + public ExtraPropertyDictionary ExtraProperties { get; set; } = new ExtraPropertyDictionary(); +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/ContainerNoteManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/ContainerNoteManager.cs new file mode 100644 index 000000000..2a339ef23 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/ContainerNoteManager.cs @@ -0,0 +1,50 @@ +using System; +using System.Threading.Tasks; +using Microsoft.Extensions.Logging; +using Volo.Abp; +using Volo.Abp.Uow; +using Win_in.Sfs.Shared.Event; + + +namespace Win_in.Sfs.Wms.Store.Domain; + +public class ContainerNoteManager : SfsStoreManagerBase, IContainerNoteManager +{ + + public ContainerNoteManager( + IContainerNoteRepository repository + ) : base(repository) + { + } + + public override async Task CreateAsync(ContainerNote ContainerNote) + { + ContainerNote = await base.CreateAsync(ContainerNote).ConfigureAwait(false); + return ContainerNote; + } + + [UnitOfWork] + public virtual async Task ConfirmAsync(Guid id) + { + var entity = await Repository.FindAsync(id).ConfigureAwait(false); + Check.NotNull(entity, EntityClassName); + entity.Confirm(Clock.Now); + await PublishConfirmedAsync(entity).ConfigureAwait(false); + return await Repository.UpdateAsync(entity).ConfigureAwait(false); + } + + private async Task PublishConfirmedAsync(ContainerNote entity) + { + try + { + await LocalEventBus.PublishAsync(new SfsConfirmedEntityEventData(entity), false).ConfigureAwait(false); + } + catch (Exception ex) + { + Logger.LogDebug($"{nameof(ContainerNote)} Confirmed Event:{ex.Message}", null); + Console.WriteLine(ex.Source); + throw; + } + } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/IContainerNoteManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/IContainerNoteManager.cs new file mode 100644 index 000000000..096785ccd --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/IContainerNoteManager.cs @@ -0,0 +1,9 @@ +using System.Threading.Tasks; +using System; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public interface IContainerNoteManager : ISfsStoreManager +{ + Task ConfirmAsync(Guid id); +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/IContainerNoteRepository.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/IContainerNoteRepository.cs new file mode 100644 index 000000000..4b714e856 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/ContainerNotes/IContainerNoteRepository.cs @@ -0,0 +1,5 @@ +namespace Win_in.Sfs.Wms.Store.Domain; + +public interface IContainerNoteRepository : ISfsStoreRepositoryBase +{ +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/IssueNotes/IssueNoteDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/IssueNotes/IssueNoteDetail.cs index 4ba4f018b..bd3fad75b 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/IssueNotes/IssueNoteDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Notes/IssueNotes/IssueNoteDetail.cs @@ -1,4 +1,5 @@ using System; +using Win_in.Sfs.Shared.Domain.Shared; namespace Win_in.Sfs.Wms.Store.Domain; @@ -29,4 +30,14 @@ public class IssueNoteDetail : SfsStoreRecommendFromDetailWithFromToEntityBase /// 在途库库位 /// public string OnTheWayLocationCode { get; set; } + + /// + /// 位置码 + /// + public string PositionCode { get; set; } + + /// + /// 推荐类型 + /// + public EnumRecommendType RecommendType { get; set; } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Orders/PurchaseOrders/IPurchaseOrderManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Orders/PurchaseOrders/IPurchaseOrderManager.cs index 6af83f78d..2ac78a39c 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Orders/PurchaseOrders/IPurchaseOrderManager.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Orders/PurchaseOrders/IPurchaseOrderManager.cs @@ -8,4 +8,5 @@ public interface IPurchaseOrderManager : ISfsStoreManager CheckIsCloseAsync(string number, string supplierCode, string itemCode); } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Orders/PurchaseOrders/PurchaseOrderManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Orders/PurchaseOrders/PurchaseOrderManager.cs index 2d8f34e8f..238abd5cf 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Orders/PurchaseOrders/PurchaseOrderManager.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Orders/PurchaseOrders/PurchaseOrderManager.cs @@ -1,8 +1,10 @@ using System; using System.Collections.Generic; +using System.Linq; using System.Threading.Tasks; using Volo.Abp; using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; namespace Win_in.Sfs.Wms.Store.Domain; @@ -24,7 +26,17 @@ public class PurchaseOrderManager : SfsStoreManagerBase + /// 打开订单明细 + /// + /// + public virtual async Task CheckIsCloseAsync(string number,string supplierCode, string itemCode) + { + bool result = false; + var entitys = await _repository.GetListAsync(p =>p.Number==number && p.Details.Any(y => y.ItemCode == itemCode&&y.LineStatus== EnumOrderStatus.Close) && p.SupplierCode == supplierCode, true).ConfigureAwait(false); + if (entitys.Count!=0) result = true; + return result; + } /// /// 打开订单明细 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/ContainerRequest.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/ContainerRequest.cs new file mode 100644 index 000000000..d2f13e5cb --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/ContainerRequest.cs @@ -0,0 +1,37 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using Win_in.Sfs.Shared.Domain.Entities; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Domain; + +/// +/// 器具呼叫申请 +/// +public class ContainerRequest : SfsStoreRequestAggregateRootBase +{ + /// + /// 呼叫库位代码 + /// + [IgnoreUpdate] + public string RequestLocationCode { get; set; } + + /// + /// 器具类型 + /// + [IgnoreUpdate] + public string ContainerType { get; set; } + + /// + /// 器具规格 + /// + [IgnoreUpdate] + public string SpecificationsType { get; set; } + + /// + /// 任务明细 + /// + [IgnoreUpdate] + public override List Details { get; set; } = new(); +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/ContainerRequestDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/ContainerRequestDetail.cs new file mode 100644 index 000000000..51ea7ee45 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/ContainerRequestDetail.cs @@ -0,0 +1,20 @@ +using Volo.Abp.Data; + +namespace Win_in.Sfs.Wms.Store.Domain; + +/// +/// 器具呼叫申请明细表 +/// +public class ContainerRequestDetail : SfsStoreDetailWithQtyEntityBase, IHasExtraProperties +{ + /// + /// 呼叫库位 + /// + public string ToLocationCode { get; set; } + + /// + /// 扩展属性 + /// + public ExtraPropertyDictionary ExtraProperties { get; set; } = new ExtraPropertyDictionary(); + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/ContainerRequestManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/ContainerRequestManager.cs new file mode 100644 index 000000000..dafd24461 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/ContainerRequestManager.cs @@ -0,0 +1,50 @@ +using System.Collections.Generic; +using System.Threading.Tasks; +using Volo.Abp.Uow; +using Win_in.Sfs.Shared.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public class ContainerRequestManager : SfsStoreRequestManagerBase, IContainerRequestManager +{ + public readonly IContainerRequestRepository _repository; + + public ContainerRequestManager( + IContainerRequestRepository repository + ) + : base(repository) + { + _repository = repository; + } + public override async Task> CreateManyAsync(List entities) + { + var results = new List(); + foreach (var entity in entities) + { + entity.SetIdAndNumberWithDetails(GuidGenerator, await GenerateNumberAsync(typeof(ContainerRequest).Name, entity.ActiveDate).ConfigureAwait(false)); + ContainerRequest result; + if (entity.AutoSubmit) + { + result = await SubmitAsync(entity).ConfigureAwait(false); + } + else + { + result = await Repository.InsertAsync(entity).ConfigureAwait(false); + } + results.Add(result); + } + return entities; + } + /// + /// 执行导入 + /// + public virtual async Task ImportDataAsync(List mergeEntities, List deleteEntities = null) + { + if (deleteEntities != null && deleteEntities.Count > 0) + { + await _repository.BulkDeleteAsync(deleteEntities).ConfigureAwait(false); + } + + await CreateManyAsync(mergeEntities).ConfigureAwait(false); + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/IContainerRequestManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/IContainerRequestManager.cs new file mode 100644 index 000000000..4c4817637 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/IContainerRequestManager.cs @@ -0,0 +1,8 @@ +namespace Win_in.Sfs.Wms.Store.Domain; + +using Win_in.Sfs.Shared.Domain; + +public interface IContainerRequestManager : ISfsStoreRequestManager, IBulkImportService +{ + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/IContainerRequestRepository.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/IContainerRequestRepository.cs new file mode 100644 index 000000000..7c928a54f --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/ContainerRequests/IContainerRequestRepository.cs @@ -0,0 +1,8 @@ +using Win_in.Sfs.Shared.Domain; + +namespace Win_in.Sfs.Wms.Store.Domain; + +public interface IContainerRequestRepository : ISfsStoreRepositoryBase, ISfsBulkRepositoryBase +{ + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestDetail.cs index 1c59a4fda..19420cba8 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestDetail.cs @@ -90,4 +90,15 @@ public class MaterialRequestDetail : SfsStoreDetailWithQtyEntityBase, IHasToLoca /// [NotMapped] public decimal NotFinishQty => Qty - ReceivedQty; + + /// + /// 位置码 + /// + public string PositionCode { get; set; } + + /// + /// 推荐类型 + /// + public EnumRecommendType RecommendType { get; set; } + } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestManager.cs index 20456a5e7..0230ea1b4 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestManager.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/MaterialRequests/MaterialRequestManager.cs @@ -46,20 +46,23 @@ public class MaterialRequestManager public virtual async Task UpdateDetailsAsync(MaterialRequest newEntity) { var oldEntity = await Repository.FindAsync(newEntity.Id, true).ConfigureAwait(false); - - foreach (var newDetail in newEntity.Details) + if(oldEntity!=null) { - oldEntity.ReplaceDetail(newDetail.Id, newDetail); - } + foreach (var newDetail in newEntity.Details) + { + oldEntity.ReplaceDetail(newDetail.Id, newDetail); + } - foreach (var detail in oldEntity.Details) - { - SetMaterialRequestDetailStatus(detail); - } + foreach (var detail in oldEntity.Details) + { + SetMaterialRequestDetailStatus(detail); + } - await SetMaterialRequestStatus(oldEntity).ConfigureAwait(false); + await SetMaterialRequestStatus(oldEntity).ConfigureAwait(false); - await Repository.UpdateAsync(oldEntity).ConfigureAwait(false); + await Repository.UpdateAsync(oldEntity).ConfigureAwait(false); + } + } private void SetMaterialRequestDetailStatus(MaterialRequestDetail detail) diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/PurchaseReceiptRequests/PurchaseReceiptRequestDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/PurchaseReceiptRequests/PurchaseReceiptRequestDetail.cs index 0bc5acf14..a15477c2a 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/PurchaseReceiptRequests/PurchaseReceiptRequestDetail.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/PurchaseReceiptRequests/PurchaseReceiptRequestDetail.cs @@ -1,3 +1,4 @@ +using System; using System.ComponentModel.DataAnnotations; using Win_in.Sfs.Shared.Domain; @@ -35,4 +36,10 @@ public class PurchaseReceiptRequestDetail : SfsStoreDetailWithLotPackingQtyEntit /// [Display(Name = "推荐ERP储位")] public string RecommendErpCode { get; set; } + + + public void SetId(Guid id) + { + this.Id = Id; + } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/PurchaseReturnRequests/PurchaseReturnRequestManager.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/PurchaseReturnRequests/PurchaseReturnRequestManager.cs index 1ae7436ae..6db0da0ca 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/PurchaseReturnRequests/PurchaseReturnRequestManager.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Requests/PurchaseReturnRequests/PurchaseReturnRequestManager.cs @@ -1,5 +1,6 @@ using System.Collections.Generic; using System.Threading.Tasks; +using Volo.Abp.Uow; using Win_in.Sfs.Shared.Domain.Shared; namespace Win_in.Sfs.Wms.Store.Domain; @@ -15,7 +16,25 @@ public class PurchaseReturnRequestManager : SfsStoreRequestManagerBase> CreateManyAsync(List entities) + { + var results = new List(); + foreach (var entity in entities) + { + entity.SetIdAndNumberWithDetails(GuidGenerator, await GenerateNumberAsync(typeof(PurchaseReturnRequest).Name, entity.ActiveDate).ConfigureAwait(false)); + PurchaseReturnRequest result; + if (entity.AutoSubmit) + { + result = await SubmitAsync(entity).ConfigureAwait(false); + } + else + { + result = await Repository.InsertAsync(entity).ConfigureAwait(false); + } + results.Add(result); + } + return entities; + } /// /// 执行导入 /// diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Win_in.Sfs.Wms.Store.Domain.csproj b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Win_in.Sfs.Wms.Store.Domain.csproj index 90a600d5c..7503698cd 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Win_in.Sfs.Wms.Store.Domain.csproj +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Domain/Win_in.Sfs.Wms.Store.Domain.csproj @@ -1,4 +1,4 @@ - + @@ -29,7 +29,6 @@ - @@ -39,10 +38,8 @@ - - diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Equipments/EquipmentRecordDbContextModelCreatingExtensions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Equipments/EquipmentRecordDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..4d27863b9 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Equipments/EquipmentRecordDbContextModelCreatingExtensions.cs @@ -0,0 +1,80 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Equipments; + +namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; + +public static class EquipmentRecordDbContextModelCreatingExtensions +{ + public static void ConfigureEquipmentRecord(this ModelBuilder builder, StoreModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(EquipmentRecord), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsStoreBase(); + + b.Property(q => q.BarCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.Batch).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.EqptCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ToLocCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.FromLocCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.PartCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.Batch).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.Type).HasMaxLength(SfsPropertyConst.CodeLength); + + + + b.HasIndex(q => new { q.EqptCode }); + + + + //Properties + //b.Property(q => q.SupplierCode).HasMaxLength(SfsPropertyConst.NameLength); + //b.Property(q => q.PoType).HasMaxLength(SfsPropertyConst.NameLength); + //b.Property(q => q.OrderStatus).HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); + //b.Property(q => q.Version).HasMaxLength(SfsPropertyConst.NameLength); + //b.Property(q => q.IsConsignment).HasDefaultValue(false); + //b.Property(q => q.TaxRate).HasDefaultValue(0); + //b.Property(q => q.ContactName).HasMaxLength(SfsPropertyConst.NameLength); + //b.Property(q => q.ContactPhone).HasMaxLength(SfsPropertyConst.NameLength); + //b.Property(q => q.ContactEmail).HasMaxLength(SfsPropertyConst.NameLength); + + ////Relations + //b.HasMany(q => q.Details).WithOne().HasForeignKey(d => d.MasterID).IsRequired(); + + ////Indexes + //b.HasIndex(q => new { q.Number }).IsUnique(); + }); + + //builder.Entity(b => + //{ + // //Configure table & schema name + // b.ToTable(options.TablePrefix + nameof(PurchaseOrderDetail), options.Schema); + // //Configure ABP properties + // b.ConfigureByConvention(); + // //Configure Sfs base properties + // b.ConfigureSfsStoreBase(); + // //Configure Sfs store detail properties + // b.ConfigureSfsStoreDetailBase(); + + // //Properties + // b.Property(q => q.PoLine).HasMaxLength(SfsPropertyConst.CodeLength); + // b.Property(q => q.LineStatus).IsRequired().HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); + // b.Property(q => q.ConvertRate).HasDefaultValue(1); + // b.Property(q => q.IsConsignment).HasDefaultValue(false); + // b.Property(q => q.ProjectCode).HasMaxLength(SfsPropertyConst.CodeLength); + // b.Property(q => q.LocationErpCode).HasMaxLength(SfsPropertyConst.CodeLength); + + // //Relations + + // //Indexes + // b.HasIndex(q => new { q.ItemCode, q.Number, q.PoLine }).IsUnique(); + //}); + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Equipments/EquipmentRecordEfCoreRepository.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Equipments/EquipmentRecordEfCoreRepository.cs new file mode 100644 index 000000000..25ab861ad --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Equipments/EquipmentRecordEfCoreRepository.cs @@ -0,0 +1,23 @@ +using System.Linq; +using System.Threading.Tasks; +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Shared.Domain; +using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Equipments; + +namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; + +public class EquipmentRecordEfCoreRepository : SfsStoreEfCoreRepositoryBase, IEquipmentRecordRepository, ISfsBulkRepositoryBase +{ + public EquipmentRecordEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } + + public Task UpsertAsync(EquipmentRecord newData) + { + throw new System.NotImplementedException(); + } + + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/ExchangeData/ExchangeDataDbContextModelCreatingExtensions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/ExchangeData/ExchangeDataDbContextModelCreatingExtensions.cs index 1321c944e..d6b66a324 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/ExchangeData/ExchangeDataDbContextModelCreatingExtensions.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/ExchangeData/ExchangeDataDbContextModelCreatingExtensions.cs @@ -30,7 +30,7 @@ public static class ExchangeDataDbContextModelCreatingExtensions b.Property(p => p.ReadTime); b.Property(p => p.ErrorCode).IsRequired().HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); b.Property(p => p.ErrorMessage).HasMaxLength(SfsPropertyConst.RemarkLength); - b.Property(p => p.TyrpNumber).IsRequired().HasDefaultValueSql(); + b.Property(p => p.TyrpNumber).IsRequired(); //.HasDefaultValueSql() //Relations //Indexes diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/IStoreDbContext.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/IStoreDbContext.cs index c99a156c0..6ce3b9881 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/IStoreDbContext.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/IStoreDbContext.cs @@ -18,6 +18,7 @@ public interface IStoreDbContext : IEfCoreDbContext public DbSet TransferRequests { get; } public DbSet ProductReceiptRequests { get; } public DbSet MaterialRequests { get; } + public DbSet ContainerRequests { get; } public DbSet DeliverRequests { get; } public DbSet InspectRequests { get; } public DbSet PutawayRequest { get; } @@ -68,6 +69,7 @@ public interface IStoreDbContext : IEfCoreDbContext public DbSet InventoryTransferNotes { get; } public DbSet WarehouseTransferNotes { get; } public DbSet IssueNotes { get; } + public DbSet ContainerNotes { get; } public DbSet UnplannedReceiptNotes { get; } public DbSet UnplannedIssueNotes { get; } public DbSet IsolationNotes { get; } @@ -92,10 +94,12 @@ public interface IStoreDbContext : IEfCoreDbContext public DbSet InspectJobs { get; } public DbSet PutawayJobs { get; } public DbSet IssueJobs { get; } + public DbSet ContainerJobs { get; } public DbSet DeliverJobs { get; } public DbSet JisDeliverJobs { get; } public DbSet PurchaseReturnJobs { get; } public DbSet ProductReceiveJobs { get; } + public DbSet ProductRecycleJobs { get; } public DbSet CheckJobs { get; } public DbSet CountJobs { get; } public DbSet UnplannedIssueJobs { get; } @@ -105,5 +109,4 @@ public interface IStoreDbContext : IEfCoreDbContext #endregion public DbSet ExchangeDatas { get; } - } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ContainerJobs/ContainerJobDbContextModelCreatingExtensions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ContainerJobs/ContainerJobDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..69a60359e --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ContainerJobs/ContainerJobDbContextModelCreatingExtensions.cs @@ -0,0 +1,57 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.EntityFrameworkCore; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; + +public static class ContainerJobDbContextModelCreatingExtensions +{ + public static void ConfigureContainerJob(this ModelBuilder builder, StoreModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(StoreDbProperties.JobDbTablePrefix + nameof(ContainerJob), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + //Configure Job base properties + b.ConfigureJob(); + //Properties + b.Property(q => q.ContainerRequestNumber).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ContainerType).HasMaxLength(SfsPropertyConst.NameLength); + b.Property(q => q.RequestLocationCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.SpecificationsType).HasMaxLength(SfsPropertyConst.NameLength); + + //Relations + b.HasMany(q => q.Details).WithOne().HasForeignKey(d => d.MasterID).IsRequired(); + //Indexes + b.HasIndex(q => new { q.Number }).IsUnique(); + }); + + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(StoreDbProperties.JobDbTablePrefix + nameof(ContainerJobDetail), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + //Configure Job base properties + b.ConfigureJobRecommendFromDetail(); + //Properties + + b.Property(q => q.ToLocationCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.FromLocationCode).HasMaxLength(SfsPropertyConst.CodeLength); + + //Relations + //None + + //Indexes + //b.HasIndex(q => new { q.PackingCode }).IsUnique(); + }); + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ContainerJobs/ContainerJobEfCoreRepository.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ContainerJobs/ContainerJobEfCoreRepository.cs new file mode 100644 index 000000000..dc8a63d42 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ContainerJobs/ContainerJobEfCoreRepository.cs @@ -0,0 +1,11 @@ +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; + +public class ContainerJobEfCoreRepository : SfsJobEfCoreRepositoryBase, IContainerJobRepository +{ + public ContainerJobEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/IssueJobs/IssueJobDbContextModelCreatingExtensions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/IssueJobs/IssueJobDbContextModelCreatingExtensions.cs index 99e7a6c1f..2a6c87990 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/IssueJobs/IssueJobDbContextModelCreatingExtensions.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/IssueJobs/IssueJobDbContextModelCreatingExtensions.cs @@ -56,6 +56,8 @@ public static class IssueJobDbContextModelCreatingExtensions b.Property(q => q.TruncType).HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); b.Property(q => q.PlannedSplitRule).HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); b.Property(q => q.OnTheWayLocationCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.PositionCode).HasMaxLength(SfsPropertyConst.CodeLength).IsRequired(false); + b.Property(q => q.RecommendType).HasMaxLength(SfsPropertyConst.CodeLength).HasConversion(); //Relations //None diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ProductRecycleJobs/ProductRecycleJobDbContextModelCreatingExtensions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ProductRecycleJobs/ProductRecycleJobDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..de07c7b69 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ProductRecycleJobs/ProductRecycleJobDbContextModelCreatingExtensions.cs @@ -0,0 +1,52 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.EntityFrameworkCore; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; + +public static class ProductRecycleJobDbContextModelCreatingExtensions +{ + public static void ConfigureProductRecycleJob(this ModelBuilder builder, StoreModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(StoreDbProperties.JobDbTablePrefix + nameof(ProductRecycleJob), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + //Configure Job base properties + b.ConfigureJob(); + //Properties + b.Property(q => q.Workshop).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.Shift).HasMaxLength(SfsPropertyConst.CodeLength); + //Relations + b.HasMany(q => q.Details).WithOne().HasForeignKey(d => d.MasterID).IsRequired(); + //Indexes + b.HasIndex(q => new { q.Number }).IsUnique(); + }); + + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(StoreDbProperties.JobDbTablePrefix + nameof(ProductRecycleJobDetail), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsBase(); + //Configure Job base properties + b.ConfigureJobRecommendToDetail(); + //Properties + + + //Relations + //None + + //Indexes + //b.HasIndex(q => new { q.PackingCode }).IsUnique(); + }); + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ProductRecycleJobs/ProductRecycleJobEfCoreRepository.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ProductRecycleJobs/ProductRecycleJobEfCoreRepository.cs new file mode 100644 index 000000000..7e7a9b688 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Jobs/ProductRecycleJobs/ProductRecycleJobEfCoreRepository.cs @@ -0,0 +1,11 @@ +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; + +public class ProductRecycleJobEfCoreRepository : SfsJobEfCoreRepositoryBase, IProductRecycleJobRepository +{ + public ProductRecycleJobEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20221024063735_ExchangeData.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20221024063735_ExchangeData.Designer.cs deleted file mode 100644 index 6873fabf7..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20221024063735_ExchangeData.Designer.cs +++ /dev/null @@ -1,17471 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20221024063735_ExchangeData")] - partial class ExchangeData - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("Relational:MaxIdentifierLength", 128) - .HasAnnotation("ProductVersion", "5.0.17") - .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_BackFlushNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasColumnType("nvarchar(450)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountAdjustNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_CountNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_CountPlan"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_CustomerAsn"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_DeliverNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_DeliverPlan"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverType") - .HasColumnType("int"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ExpiredTime", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint") - .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_InspectNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_InspectRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveUom") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_IsolationNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_IssueNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RawLocation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_PreparationPlan"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PRRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_ProductionPlan"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_PutawayNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayJobType") - .HasColumnType("int"); - - b.Property("PutawayType") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_PutawayRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "Company", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_SaleOrder"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_ScrapNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_SupplierAsn"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NeedInTransitLocation") - .HasColumnType("bit"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_TransferNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InTransitLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NeedInTransitLocation") - .HasColumnType("bit"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_TransferRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InTransitLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Company", "Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Company") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Company"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number", "Company") - .IsUnique(); - - b.ToTable("Store_WorkOrder"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "AuditCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasColumnType("nvarchar(max)"); - - b1.Property("Operator") - .HasColumnType("nvarchar(max)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "FirstCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasColumnType("nvarchar(max)"); - - b1.Property("Operator") - .HasColumnType("nvarchar(max)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "RepeatCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasColumnType("nvarchar(max)"); - - b1.Property("Operator") - .HasColumnType("nvarchar(max)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.Navigation("AuditCount"); - - b.Navigation("Batch"); - - b.Navigation("FirstCount"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RepeatCount"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "AuditCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasColumnType("nvarchar(max)"); - - b1.Property("Operator") - .HasColumnType("nvarchar(max)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "FirstCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasColumnType("nvarchar(max)"); - - b1.Property("Operator") - .HasColumnType("nvarchar(max)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "RepeatCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasColumnType("nvarchar(max)"); - - b1.Property("Operator") - .HasColumnType("nvarchar(max)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.Navigation("AuditCount"); - - b.Navigation("Batch"); - - b.Navigation("FirstCount"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RepeatCount"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("CustomerAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.Property("Phone") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CustomerAsnId"); - - b1.ToTable("Store_CustomerAsn"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CustomerAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CustomerAsnId"); - - b1.ToTable("Store_CustomerAsn"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnId"); - }); - - b.Navigation("Contacts"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("InspectAbnormalNoteDetailId", "PhotoID"); - - b1.ToTable("Store_InspectAbnormalNoteDetailPhoto"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Photos"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "InspectUser", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.Property("Phone") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("InspectNoteDetailId", "PhotoID"); - - b1.ToTable("Store_InspectNoteDetailPhoto"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InspectUser"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Photos"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "InspectUser", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.Property("Phone") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InspectUser"); - - b.Navigation("Item"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "FromQty", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ToQty", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("FromQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - - b.Navigation("ToQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "FromQty", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ToQty", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("FromQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - - b.Navigation("ToQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductL7PartsNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductL7PartsNoteDetailId"); - - b1.ToTable("Store_ProductL7PartsNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductL7PartsNoteDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "RawLocation", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("RawLocation"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "RawLocation", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("RawLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PlanQty", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("PlanQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("PurchaseOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.Property("Phone") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseOrderId"); - - b1.ToTable("Store_PurchaseOrder"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("ReceiptAbnormalNoteDetailId", "PhotoID"); - - b1.ToTable("Store_ReceiptAbnormalNotePhoto"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Photos"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("SaleOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.Property("Phone") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SaleOrderId"); - - b1.ToTable("Store_SaleOrder"); - - b1.WithOwner() - .HasForeignKey("SaleOrderId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "CustomerPack", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.Navigation("CustomerPack"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("SupplierAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.Property("Phone") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SupplierAsnId"); - - b1.ToTable("Store_SupplierAsn"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasColumnType("nvarchar(max)"); - - b1.Property("ErpCode") - .HasColumnType("nvarchar(max)"); - - b1.Property("Group") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasColumnType("nvarchar(max)"); - - b1.Property("Desc2") - .HasColumnType("nvarchar(max)"); - - b1.Property("Name") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "RawQty", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("RawQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20221024063735_ExchangeData.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20221024063735_ExchangeData.cs deleted file mode 100644 index 41588d92f..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20221024063735_ExchangeData.cs +++ /dev/null @@ -1,5641 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class ExchangeData : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.CreateTable( - name: "Store_PurchaseReceiptRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - TruckNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DockCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - TimeWindow = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: false), - PlanArriveDate = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PurchaseReceiptRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_BackFlushNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: false), - Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductionPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ProductReceiptNumber = table.Column(type: "nvarchar(max)", nullable: true), - ProductRecycleNumber = table.Column(type: "nvarchar(max)", nullable: true), - JobNumber = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_BackFlushNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ContainerBindNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - BindType = table.Column(type: "int", nullable: false), - BindTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ContainerBindNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_CountAdjustNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CountNoteNumber = table.Column(type: "nvarchar(max)", nullable: true), - CountPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CountAdjustNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_CountNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CountPlanNumber = table.Column(type: "nvarchar(max)", nullable: true), - Type = table.Column(type: "int", nullable: false), - Stage = table.Column(type: "int", nullable: false), - Description = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - BeginTime = table.Column(type: "datetime2", nullable: false), - EndTime = table.Column(type: "datetime2", nullable: false), - Adjusted = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CountNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_CountPlan", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Type = table.Column(type: "int", nullable: false), - Stage = table.Column(type: "int", nullable: false, defaultValue: 1), - Description = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - BeginTime = table.Column(type: "datetime2", nullable: false), - EndTime = table.Column(type: "datetime2", nullable: false), - PlanTime = table.Column(type: "datetime2", nullable: false), - CountMethod = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CountPlan", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_CustomerAsn", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - SoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Status = table.Column(type: "int", nullable: false), - Contacts_Name = table.Column(type: "nvarchar(max)", nullable: true), - Contacts_Phone = table.Column(type: "nvarchar(max)", nullable: true), - Contacts_Email = table.Column(type: "nvarchar(max)", nullable: true), - DockCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - TimeRange_BeginTime = table.Column(type: "datetime2", nullable: true), - TimeRange_EndTime = table.Column(type: "datetime2", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CustomerAsn", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_CustomerReturnNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReturnTime = table.Column(type: "datetime2", nullable: false), - Customer = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CustomerReturnNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_DeliverNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Customer = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CustomerAddressCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_DeliverNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_DeliverPlan", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PlanDate = table.Column(type: "datetime2", nullable: false), - PlanTime = table.Column(type: "datetime2", nullable: false), - CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CustomerAddressCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Project = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_DeliverPlan", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_DeliverRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - DeliverPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - DeliverType = table.Column(type: "int", nullable: false), - CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CustomerAddressCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_DeliverRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ExchangeData", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Number = table.Column(type: "bigint", nullable: false) - .Annotation("SqlServer:Identity", "1, 1"), - DataType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - DataAction = table.Column(type: "int", nullable: false), - EffectiveDate = table.Column(type: "datetime2(7)", nullable: false), - Status = table.Column(type: "int", nullable: false), - DataIdentityCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - DataContent = table.Column(type: "nvarchar(max)", nullable: true), - DestinationSystem = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ReadTime = table.Column(type: "datetime2", nullable: true), - Reader = table.Column(type: "nvarchar(max)", nullable: true), - SourceSystem = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - WriteTime = table.Column(type: "datetime2", nullable: false), - Writer = table.Column(type: "nvarchar(max)", nullable: true), - ErrorCode = table.Column(type: "int", nullable: false), - ErrorMessage = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - RetryTimes = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ExchangeData", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectAbnormalNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - InspectNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectAbnormalNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - InspectNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - NextAction = table.Column(type: "int", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_InventoryTransferNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - TransferType = table.Column(type: "int", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InventoryTransferNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_IsolationNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_IsolationNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_IssueNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_IssueNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ItemTransformNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobNumber = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ItemTransformNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ItemTransformRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ItemTransformRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_JisDeliverNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Customer = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CustomerAddressCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ProjectCode = table.Column(type: "nvarchar(max)", nullable: true), - DeliverTime = table.Column(type: "datetime2", nullable: false), - ContainerQty = table.Column(type: "decimal(18,6)", nullable: false), - ItemQty = table.Column(type: "decimal(18,6)", nullable: false), - TotalPackCapacity = table.Column(type: "nvarchar(max)", nullable: true), - ArrivalTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_JisDeliverNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_JisProductReceiptNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReceiptType = table.Column(type: "int", nullable: false), - SourceNumber = table.Column(type: "nvarchar(max)", nullable: true), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductionPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationCode = table.Column(type: "nvarchar(max)", nullable: true), - RawLocation = table.Column(type: "nvarchar(max)", nullable: true), - ProdLine = table.Column(type: "nvarchar(max)", nullable: true), - WorkShop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: false), - ContainerQty = table.Column(type: "decimal(18,6)", nullable: false), - ItemQty = table.Column(type: "decimal(18,6)", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_JisProductReceiptNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_MaterialRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PreparationPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false, defaultValue: 1) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_MaterialRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_OfflineSettlementNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(max)", nullable: true), - ProductReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_OfflineSettlementNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_PreparationPlan", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ProductionPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Team = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PlanDate = table.Column(type: "datetime2", nullable: false), - PlanTime = table.Column(type: "datetime2", nullable: false), - Status = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PreparationPlan", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductionPlan", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Team = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - PlanDate = table.Column(type: "datetime2", nullable: false), - PlanTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductionPlan", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductionReturnNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductionReturnRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReturnTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductionReturnNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductionReturnRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false, defaultValue: 1) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductionReturnRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductL7PartsNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Year = table.Column(type: "nvarchar(max)", nullable: true), - ProductNo = table.Column(type: "nvarchar(max)", nullable: true), - Program = table.Column(type: "nvarchar(max)", nullable: true), - Position = table.Column(type: "nvarchar(max)", nullable: true), - FATA = table.Column(type: "nvarchar(max)", nullable: true), - Configuration = table.Column(type: "nvarchar(max)", nullable: true), - ContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - State = table.Column(type: "int", nullable: false), - CreateDate = table.Column(type: "datetime2", nullable: false), - Status = table.Column(type: "int", nullable: false), - ReceiptNumber = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductL7PartsNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductReceiptNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReceiptType = table.Column(type: "int", nullable: false), - SourceNumber = table.Column(type: "nvarchar(max)", nullable: true), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductionPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WorkShop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductReceiptNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductReceiptRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ProductionPlanNumber = table.Column(type: "nvarchar(max)", nullable: true), - Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Team = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - PlanDate = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductReceiptRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductRecycleNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PRRequestNumber = table.Column(type: "nvarchar(max)", nullable: true), - RecycleTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductRecycleNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductRecycleRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductRecycleRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_PurchaseOrder", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - OrderStatus = table.Column(type: "int", nullable: false), - IsConsignment = table.Column(type: "bit", nullable: false, defaultValue: false), - OrderDate = table.Column(type: "datetime2", nullable: false), - DueDate = table.Column(type: "datetime2", nullable: false), - Version = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - TaxRate = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - Contacts_Name = table.Column(type: "nvarchar(max)", nullable: true), - Contacts_Phone = table.Column(type: "nvarchar(max)", nullable: true), - Contacts_Email = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PurchaseOrder", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_PurchaseReceiptNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ReceiveTime = table.Column(type: "datetime2", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Type = table.Column(type: "int", nullable: false), - Status = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PurchaseReceiptNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_PurchaseReturnNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PurchaseReturnRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReturnReason = table.Column(type: "nvarchar(max)", nullable: true), - ReturnTime = table.Column(type: "datetime2", nullable: false), - ReturnType = table.Column(type: "int", nullable: false, defaultValue: 2), - Status = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PurchaseReturnNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_PurchaseReturnRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReturnTime = table.Column(type: "datetime2", nullable: false), - ReturnType = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PurchaseReturnRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_PutawayNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - InspectNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PutawayNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_PutawayRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PutawayJobType = table.Column(type: "int", nullable: false), - SupplierCode = table.Column(type: "nvarchar(max)", nullable: true), - InspectNumber = table.Column(type: "nvarchar(max)", nullable: true), - ReceiptNumber = table.Column(type: "nvarchar(max)", nullable: true), - PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(max)", nullable: true), - AsnNumber = table.Column(type: "nvarchar(max)", nullable: true), - RpNumber = table.Column(type: "nvarchar(max)", nullable: true), - PoNumber = table.Column(type: "nvarchar(max)", nullable: true), - ProductReceiptNumber = table.Column(type: "nvarchar(max)", nullable: true), - PutawayType = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PutawayRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ReceiptAbnormalNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ReceiptAbnormalNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_RecycledMaterialReceiptNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_RecycledMaterialReceiptNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_SaleOrder", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SoType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SoStatus = table.Column(type: "int", nullable: false), - OrderDate = table.Column(type: "datetime2", nullable: false), - DueDate = table.Column(type: "datetime2", nullable: false), - Version = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - TaxRate = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - Contacts_Name = table.Column(type: "nvarchar(max)", nullable: true), - Contacts_Phone = table.Column(type: "nvarchar(max)", nullable: true), - Contacts_Email = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_SaleOrder", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ScrapNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ScrapNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_SupplierAsn", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Status = table.Column(type: "int", nullable: false), - Contacts_Name = table.Column(type: "nvarchar(max)", nullable: true), - Contacts_Phone = table.Column(type: "nvarchar(max)", nullable: true), - Contacts_Email = table.Column(type: "nvarchar(max)", nullable: true), - TruckNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DockCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ShipDate = table.Column(type: "datetime2", nullable: false), - DueDate = table.Column(type: "datetime2", nullable: false), - TimeWindow = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - PlanArriveDate = table.Column(type: "datetime2", nullable: false), - Ctype = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_SupplierAsn", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_TransferNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RequestNumber = table.Column(type: "nvarchar(max)", nullable: true), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - TransferType = table.Column(type: "int", nullable: false), - NeedInTransitLocation = table.Column(type: "bit", nullable: false), - Adjusted = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_TransferNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_TransferRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - TransferType = table.Column(type: "int", nullable: false), - NeedInTransitLocation = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_TransferRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_UnplannedIssueNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - BuildDate = table.Column(type: "datetime2", nullable: false), - UnplannedIssueRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_UnplannedIssueNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_UnplannedIssueRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - BuildDate = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_UnplannedIssueRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_UnplannedReceiptNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - BuildDate = table.Column(type: "datetime2", nullable: false), - UnplannedReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_UnplannedReceiptNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_UnplannedReceiptRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - BuildDate = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_UnplannedReceiptRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_WarehouseTransferNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_WarehouseTransferNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_WorkOrder", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - WorkOrderId = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - EffectiveDate = table.Column(type: "datetime2", nullable: false), - WorkStation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WoStatus = table.Column(type: "int", nullable: false), - Op = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Type = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Company = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_WorkOrder", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_PurchaseReceiptRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - ConvertRate = table.Column(type: "decimal(18,6)", nullable: false), - ArriveDate = table.Column(type: "datetime2", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PurchaseReceiptRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_PurchaseReceiptRequestDetail_Store_PurchaseReceiptRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_PurchaseReceiptRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_BackFlushNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsOffLine = table.Column(type: "bit", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(450)", nullable: true), - Lot = table.Column(type: "nvarchar(450)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(max)", nullable: true), - ContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_BackFlushNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_BackFlushNoteDetail_Store_BackFlushNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_BackFlushNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ContainerBindNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ContainerBindNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ContainerBindNoteDetail_Store_ContainerBindNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_ContainerBindNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_CountAdjustNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CountLabel = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - InventoryQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - InventoryQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - Type = table.Column(type: "int", nullable: false), - ReasonCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CountQty = table.Column(type: "decimal(18,6)", nullable: false), - AdjustQty = table.Column(type: "decimal(18,6)", nullable: false), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CountAdjustNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_CountAdjustNoteDetail_Store_CountAdjustNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_CountAdjustNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_CountNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CountPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CountLabel = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - InventoryQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - InventoryQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - FirstCount_Qty = table.Column(type: "decimal(18,6)", nullable: true), - FirstCount_Time = table.Column(type: "datetime2", nullable: true), - FirstCount_Operator = table.Column(type: "nvarchar(max)", nullable: true), - FirstCount_Description = table.Column(type: "nvarchar(max)", nullable: true), - RepeatCount_Qty = table.Column(type: "decimal(18,6)", nullable: true), - RepeatCount_Time = table.Column(type: "datetime2", nullable: true), - RepeatCount_Operator = table.Column(type: "nvarchar(max)", nullable: true), - RepeatCount_Description = table.Column(type: "nvarchar(max)", nullable: true), - AuditCount_Qty = table.Column(type: "decimal(18,6)", nullable: true), - AuditCount_Time = table.Column(type: "datetime2", nullable: true), - AuditCount_Operator = table.Column(type: "nvarchar(max)", nullable: true), - AuditCount_Description = table.Column(type: "nvarchar(max)", nullable: true), - FinalCountQty = table.Column(type: "decimal(18,6)", nullable: false), - DetailStatus = table.Column(type: "int", nullable: false), - Stage = table.Column(type: "int", nullable: false), - Adjusted = table.Column(type: "bit", nullable: false), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CountNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_CountNoteDetail_Store_CountNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_CountNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_CountPlanDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CountLabel = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - InventoryQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - InventoryQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - FirstCount_Qty = table.Column(type: "decimal(18,6)", nullable: true), - FirstCount_Time = table.Column(type: "datetime2", nullable: true), - FirstCount_Operator = table.Column(type: "nvarchar(max)", nullable: true), - FirstCount_Description = table.Column(type: "nvarchar(max)", nullable: true), - RepeatCount_Qty = table.Column(type: "decimal(18,6)", nullable: true), - RepeatCount_Time = table.Column(type: "datetime2", nullable: true), - RepeatCount_Operator = table.Column(type: "nvarchar(max)", nullable: true), - RepeatCount_Description = table.Column(type: "nvarchar(max)", nullable: true), - AuditCount_Qty = table.Column(type: "decimal(18,6)", nullable: true), - AuditCount_Time = table.Column(type: "datetime2", nullable: true), - AuditCount_Operator = table.Column(type: "nvarchar(max)", nullable: true), - AuditCount_Description = table.Column(type: "nvarchar(max)", nullable: true), - FinalCountQty = table.Column(type: "decimal(18,6)", nullable: false), - DetailStatus = table.Column(type: "int", nullable: false), - Stage = table.Column(type: "int", nullable: false), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CountPlanDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_CountPlanDetail_Store_CountPlan_MasterID", - column: x => x.MasterID, - principalTable: "Store_CountPlan", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_CustomerAsnDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - SoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CustomerAsnDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_CustomerAsnDetail_Store_CustomerAsn_MasterID", - column: x => x.MasterID, - principalTable: "Store_CustomerAsn", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_CustomerReturnNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CustomerReturnNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_CustomerReturnNoteDetail_Store_CustomerReturnNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_CustomerReturnNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_DeliverNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - DeliverTime = table.Column(type: "datetime2", nullable: false), - ExpiredTime = table.Column(type: "datetime2", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_DeliverNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_DeliverNoteDetail_Store_DeliverNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_DeliverNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_DeliverPlanDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - SoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_DeliverPlanDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_DeliverPlanDetail_Store_DeliverPlan_MasterID", - column: x => x.MasterID, - principalTable: "Store_DeliverPlan", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_DeliverRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ExpiredTime = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_DeliverRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_DeliverRequestDetail_Store_DeliverRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_DeliverRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectAbnormalNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - AbnormalType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectAbnormalNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_InspectAbnormalNoteDetail_Store_InspectAbnormalNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_InspectAbnormalNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - InspectType = table.Column(type: "int", nullable: false), - SamplePercent = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - ReceiveQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - ReceiveQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - InspectQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - GoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - FailedReason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FailedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - CrackQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - InspectUser_Name = table.Column(type: "nvarchar(max)", nullable: true), - InspectUser_Phone = table.Column(type: "nvarchar(max)", nullable: true), - InspectUser_Email = table.Column(type: "nvarchar(max)", nullable: true), - NotPassedQty = table.Column(type: "decimal(18,6)", nullable: false), - DetailInspectStatus = table.Column(type: "int", nullable: false), - SupplierPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - AbcClass = table.Column(type: "nvarchar(max)", nullable: true), - Appearance = table.Column(type: "nvarchar(max)", nullable: true), - Volume = table.Column(type: "nvarchar(max)", nullable: true), - Weight = table.Column(type: "nvarchar(max)", nullable: true), - OtherPropertyJson = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_InspectNoteDetail_Store_InspectNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_InspectNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectNoteSummaryDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - InspectType = table.Column(type: "int", nullable: false), - SamplePercent = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - ReceiveQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - ReceiveQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - InspectQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - GoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - FailedReason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FailedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - CrackQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - InspectUser_Name = table.Column(type: "nvarchar(max)", nullable: true), - InspectUser_Phone = table.Column(type: "nvarchar(max)", nullable: true), - InspectUser_Email = table.Column(type: "nvarchar(max)", nullable: true), - NotPassedQty = table.Column(type: "decimal(18,6)", nullable: false), - SummaryInspectStatus = table.Column(type: "int", nullable: false), - AbcClass = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectNoteSummaryDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_InspectNoteSummaryDetail_Store_InspectNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_InspectNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - InspectType = table.Column(type: "int", nullable: false), - SamplePercent = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - ReceiveQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - ReceiveQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - InspectQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - Attributes = table.Column(type: "nvarchar(max)", nullable: true), - ReceiveUom = table.Column(type: "nvarchar(max)", nullable: true), - DetailInspectStatus = table.Column(type: "int", nullable: false), - AbcClass = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_InspectRequestDetail_Store_InspectRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_InspectRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectRequestSummaryDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - InspectType = table.Column(type: "int", nullable: false), - SamplePercent = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - ReceiveQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - ReceiveQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - InspectQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - InspectReport = table.Column(type: "nvarchar(max)", nullable: true), - SummaryInspectStatus = table.Column(type: "int", nullable: false), - GoodQty = table.Column(type: "decimal(18,6)", nullable: false), - FailedQty = table.Column(type: "decimal(18,6)", nullable: false), - CrackQty = table.Column(type: "decimal(18,6)", nullable: false), - NotPassedQty = table.Column(type: "decimal(18,6)", nullable: false), - AbcClass = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectRequestSummaryDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_InspectRequestSummaryDetail_Store_InspectRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_InspectRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_InventoryTransferNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Reason = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InventoryTransferNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_InventoryTransferNoteDetail_Store_InventoryTransferNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_InventoryTransferNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_IsolationNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_IsolationNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_IsolationNoteDetail_Store_IsolationNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_IsolationNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_IssueNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - IssueTime = table.Column(type: "datetime2", nullable: false), - ExpiredTime = table.Column(type: "datetime2", nullable: false), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WorkStation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_IssueNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_IssueNoteDetail_Store_IssueNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_IssueNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ItemTransformNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - FromQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - FromQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - FromBatch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - FromBatch_ArriveDate = table.Column(type: "datetime2", nullable: true), - FromBatch_ProduceDate = table.Column(type: "datetime2", nullable: true), - FromBatch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - FromStatus = table.Column(type: "int", nullable: false), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToItemCode = table.Column(type: "nvarchar(max)", nullable: true), - ToItem_Name = table.Column(type: "nvarchar(max)", nullable: true), - ToItem_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - ToItem_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - ToQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - ToBatch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - ToBatch_ArriveDate = table.Column(type: "datetime2", nullable: true), - ToBatch_ProduceDate = table.Column(type: "datetime2", nullable: true), - ToBatch_ExpireDate = table.Column(type: "datetime2", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - ToStatus = table.Column(type: "int", nullable: false), - ToLocationCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - LocationCode = table.Column(type: "nvarchar(max)", nullable: true), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ItemTransformNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ItemTransformNoteDetail_Store_ItemTransformNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_ItemTransformNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ItemTransformRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - LocationCode = table.Column(type: "nvarchar(max)", nullable: true), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - FromQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - FromQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - FromBatch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - FromBatch_ArriveDate = table.Column(type: "datetime2", nullable: true), - FromBatch_ProduceDate = table.Column(type: "datetime2", nullable: true), - FromBatch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - FromStatus = table.Column(type: "int", nullable: false), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToItem_Name = table.Column(type: "nvarchar(max)", nullable: true), - ToItem_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - ToItem_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ToItemCode = table.Column(type: "nvarchar(max)", nullable: true), - ToBatch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - ToBatch_ArriveDate = table.Column(type: "datetime2", nullable: true), - ToBatch_ProduceDate = table.Column(type: "datetime2", nullable: true), - ToBatch_ExpireDate = table.Column(type: "datetime2", nullable: true), - ToQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - ToQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - ToStatus = table.Column(type: "int", nullable: false), - ToLocationCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ItemTransformRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ItemTransformRequestDetail_Store_ItemTransformRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_ItemTransformRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_JisDeliverNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - DeliverTime = table.Column(type: "datetime2", nullable: false), - ExpiredTime = table.Column(type: "datetime2", nullable: false), - Year = table.Column(type: "nvarchar(max)", nullable: true), - ProductNo = table.Column(type: "nvarchar(max)", nullable: true), - ProjectCode = table.Column(type: "nvarchar(max)", nullable: true), - Position = table.Column(type: "nvarchar(max)", nullable: true), - SeqNo = table.Column(type: "nvarchar(max)", nullable: true), - PackCapacity = table.Column(type: "nvarchar(max)", nullable: true), - OnlineType = table.Column(type: "nvarchar(max)", nullable: true), - Stage = table.Column(type: "nvarchar(max)", nullable: true), - UsedFor = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_JisDeliverNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_JisDeliverNoteDetail_Store_JisDeliverNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_JisDeliverNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_JisProductReceiptNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RawLocation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Year = table.Column(type: "nvarchar(max)", nullable: true), - ProductNo = table.Column(type: "nvarchar(max)", nullable: true), - ProjectCode = table.Column(type: "nvarchar(max)", nullable: true), - Position = table.Column(type: "nvarchar(max)", nullable: true), - SeqNo = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_JisProductReceiptNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_JisProductReceiptNoteDetail_Store_JisProductReceiptNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_JisProductReceiptNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_MaterialRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WorkStation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExpiredTime = table.Column(type: "datetime2", nullable: false), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - IssuedQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), - ReceivedQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), - Status = table.Column(type: "int", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_MaterialRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_MaterialRequestDetail_Store_MaterialRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_MaterialRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_OfflineSettlementNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_OfflineSettlementNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_OfflineSettlementNoteDetail_Store_OfflineSettlementNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_OfflineSettlementNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_PreparationPlanDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - WorkStation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LineStatus = table.Column(type: "int", nullable: false), - LatestTime = table.Column(type: "datetime2", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PreparationPlanDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_PreparationPlanDetail_Store_PreparationPlan_MasterID", - column: x => x.MasterID, - principalTable: "Store_PreparationPlan", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductionPlanDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PlanQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - PlanQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - GoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 1m), - NoGoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 1m), - BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LineStatus = table.Column(type: "int", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductionPlanDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ProductionPlanDetail_Store_ProductionPlan_MasterID", - column: x => x.MasterID, - principalTable: "Store_ProductionPlan", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductionReturnNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductionReturnNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ProductionReturnNoteDetail_Store_ProductionReturnNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_ProductionReturnNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductionReturnRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(max)", nullable: true), - ToLocationCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductionReturnRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ProductionReturnRequestDetail_Store_ProductionReturnRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_ProductionReturnRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductL7PartsNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RowID = table.Column(type: "int", nullable: false), - ProductNo = table.Column(type: "nvarchar(450)", nullable: true), - Program = table.Column(type: "nvarchar(max)", nullable: true), - Position = table.Column(type: "nvarchar(450)", nullable: true), - FATA = table.Column(type: "nvarchar(max)", nullable: true), - Configuration = table.Column(type: "nvarchar(450)", nullable: true), - L7Part = table.Column(type: "nvarchar(450)", nullable: true), - CanMake = table.Column(type: "bit", nullable: false), - CanBuy = table.Column(type: "bit", nullable: false), - RawLocation = table.Column(type: "nvarchar(max)", nullable: true), - LocationCode = table.Column(type: "nvarchar(max)", nullable: true), - ProdLine = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Qty = table.Column(type: "int", nullable: false), - State = table.Column(type: "int", nullable: false), - CreateDate = table.Column(type: "datetime2", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductL7PartsNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ProductL7PartsNoteDetail_Store_ProductL7PartsNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_ProductL7PartsNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductReceiptNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RawLocation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductReceiptNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ProductReceiptNoteDetail_Store_ProductReceiptNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_ProductReceiptNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductReceiptRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductReceiptRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ProductReceiptRequestDetail_Store_ProductReceiptRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_ProductReceiptRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductRecycleNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RawLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RawLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - RawLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - RawLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ReasonCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductRecycleNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ProductRecycleNoteDetail_Store_ProductRecycleNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_ProductRecycleNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductRecycleRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - RawLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RawLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - RawLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - RawLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductRecycleRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ProductRecycleRequestDetail_Store_ProductRecycleRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_ProductRecycleRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_PurchaseOrderDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - ConvertRate = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 1m), - IsConsignment = table.Column(type: "bit", nullable: false, defaultValue: false), - LineStatus = table.Column(type: "int", nullable: false), - LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProjectCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PurchaseOrderDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_PurchaseOrderDetail_Store_PurchaseOrder_MasterID", - column: x => x.MasterID, - principalTable: "Store_PurchaseOrder", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_PurchaseReceiptNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PurchaseReceiptInspectStatus = table.Column(type: "int", nullable: false), - InspectPhotoJson = table.Column(type: "nvarchar(max)", nullable: true), - FailedReason = table.Column(type: "nvarchar(max)", nullable: true), - MassDefect = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PurchaseReceiptNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_PurchaseReceiptNoteDetail_Store_PurchaseReceiptNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_PurchaseReceiptNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_PurchaseReturnNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Reason = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PurchaseReturnNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_PurchaseReturnNoteDetail_Store_PurchaseReturnNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_PurchaseReturnNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_PurchaseReturnRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PurchaseReturnRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_PurchaseReturnRequestDetail_Store_PurchaseReturnRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_PurchaseReturnRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_PutawayNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PutawayNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_PutawayNoteDetail_Store_PutawayNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_PutawayNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_PutawayRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - InventoryQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - InventoryQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_PutawayRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_PutawayRequestDetail_Store_PutawayRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_PutawayRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ReceiptAbnormalNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - AbnormalType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ReceiptAbnormalNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ReceiptAbnormalNoteDetail_Store_ReceiptAbnormalNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_ReceiptAbnormalNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_RecycledMaterialReceiptNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_RecycledMaterialReceiptNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_RecycledMaterialReceiptNoteDetail_Store_RecycledMaterialReceiptNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_RecycledMaterialReceiptNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_SaleOrderDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - SoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CustomerPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - CustomerPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - ConvertRate = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 1m), - LineStatus = table.Column(type: "int", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_SaleOrderDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_SaleOrderDetail_Store_SaleOrder_MasterID", - column: x => x.MasterID, - principalTable: "Store_SaleOrder", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ScrapNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReasonCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ScrapNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ScrapNoteDetail_Store_ScrapNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_ScrapNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_SupplierAsnDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - ConvertRate = table.Column(type: "decimal(18,6)", nullable: false), - LocationErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ProjectCode = table.Column(type: "nvarchar(max)", nullable: true), - Ctype = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_SupplierAsnDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_SupplierAsnDetail_Store_SupplierAsn_MasterID", - column: x => x.MasterID, - principalTable: "Store_SupplierAsn", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_TransferNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - InTransitLocation = table.Column(type: "nvarchar(max)", nullable: true), - Reason = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_TransferNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_TransferNoteDetail_Store_TransferNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_TransferNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_TransferRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - InTransitLocation = table.Column(type: "nvarchar(max)", nullable: true), - Reason = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_TransferRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_TransferRequestDetail_Store_TransferRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_TransferRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_UnplannedIssueNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_UnplannedIssueNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_UnplannedIssueNoteDetail_Store_UnplannedIssueNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_UnplannedIssueNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_UnplannedIssueRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_UnplannedIssueRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_UnplannedIssueRequestDetail_Store_UnplannedIssueRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_UnplannedIssueRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_UnplannedReceiptNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_UnplannedReceiptNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_UnplannedReceiptNoteDetail_Store_UnplannedReceiptNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_UnplannedReceiptNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_UnplannedReceiptRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(max)", nullable: true), - Location_Area = table.Column(type: "nvarchar(max)", nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_UnplannedReceiptRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_UnplannedReceiptRequestDetail_Store_UnplannedReceiptRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_UnplannedReceiptRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_WarehouseTransferNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Reason = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(max)", nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(max)", nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(max)", nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(max)", nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_WarehouseTransferNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_WarehouseTransferNoteDetail_Store_WarehouseTransferNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_WarehouseTransferNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_WorkOrderDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - EffectiveDate = table.Column(type: "datetime2", nullable: false), - Op = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RawQty_Uom = table.Column(type: "nvarchar(max)", nullable: true), - RawQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - RawLocation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(max)", nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_WorkOrderDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_WorkOrderDetail_Store_WorkOrder_MasterID", - column: x => x.MasterID, - principalTable: "Store_WorkOrder", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectAbnormalNoteDetailPhoto", - columns: table => new - { - PhotoID = table.Column(type: "uniqueidentifier", nullable: false), - InspectAbnormalNoteDetailId = table.Column(type: "uniqueidentifier", nullable: false), - MasterID = table.Column(type: "uniqueidentifier", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectAbnormalNoteDetailPhoto", x => new { x.InspectAbnormalNoteDetailId, x.PhotoID }); - table.ForeignKey( - name: "FK_Store_InspectAbnormalNoteDetailPhoto_Store_InspectAbnormalNoteDetail_InspectAbnormalNoteDetailId", - column: x => x.InspectAbnormalNoteDetailId, - principalTable: "Store_InspectAbnormalNoteDetail", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectNoteDetailPhoto", - columns: table => new - { - PhotoID = table.Column(type: "uniqueidentifier", nullable: false), - InspectNoteDetailId = table.Column(type: "uniqueidentifier", nullable: false), - MasterID = table.Column(type: "uniqueidentifier", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectNoteDetailPhoto", x => new { x.InspectNoteDetailId, x.PhotoID }); - table.ForeignKey( - name: "FK_Store_InspectNoteDetailPhoto_Store_InspectNoteDetail_InspectNoteDetailId", - column: x => x.InspectNoteDetailId, - principalTable: "Store_InspectNoteDetail", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ReceiptAbnormalNotePhoto", - columns: table => new - { - PhotoID = table.Column(type: "uniqueidentifier", nullable: false), - ReceiptAbnormalNoteDetailId = table.Column(type: "uniqueidentifier", nullable: false), - MasterID = table.Column(type: "uniqueidentifier", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ReceiptAbnormalNotePhoto", x => new { x.ReceiptAbnormalNoteDetailId, x.PhotoID }); - table.ForeignKey( - name: "FK_Store_ReceiptAbnormalNotePhoto_Store_ReceiptAbnormalNoteDetail_ReceiptAbnormalNoteDetailId", - column: x => x.ReceiptAbnormalNoteDetailId, - principalTable: "Store_ReceiptAbnormalNoteDetail", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptRequest_Number_Company", - table: "Store_PurchaseReceiptRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptRequest_SupplierCode", - table: "Store_PurchaseReceiptRequest", - column: "SupplierCode"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptRequestDetail_MasterID", - table: "Store_PurchaseReceiptRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptRequestDetail_Number_PackingCode", - table: "Store_PurchaseReceiptRequestDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_BackFlushNote_Number_Company", - table: "Store_BackFlushNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_BackFlushNoteDetail_MasterID", - table: "Store_BackFlushNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_BackFlushNoteDetail_Number_ItemCode_Lot", - table: "Store_BackFlushNoteDetail", - columns: new[] { "Number", "ItemCode", "Lot" }, - unique: true, - filter: "[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ContainerBindNote_Number_Company", - table: "Store_ContainerBindNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ContainerBindNoteDetail_MasterID", - table: "Store_ContainerBindNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ContainerBindNoteDetail_Number_PackingCode", - table: "Store_ContainerBindNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountAdjustNote_Number_Company", - table: "Store_CountAdjustNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountAdjustNoteDetail_MasterID", - table: "Store_CountAdjustNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountAdjustNoteDetail_Number_CountLabel", - table: "Store_CountAdjustNoteDetail", - columns: new[] { "Number", "CountLabel" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountNote_Number_Company", - table: "Store_CountNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountNoteDetail_MasterID", - table: "Store_CountNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountNoteDetail_Number_CountLabel", - table: "Store_CountNoteDetail", - columns: new[] { "Number", "CountLabel" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountPlan_Number_Company", - table: "Store_CountPlan", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountPlanDetail_MasterID", - table: "Store_CountPlanDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountPlanDetail_Number_CountLabel", - table: "Store_CountPlanDetail", - columns: new[] { "Number", "CountLabel" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerAsn_CustomerCode", - table: "Store_CustomerAsn", - column: "CustomerCode"); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerAsn_Number_Company", - table: "Store_CustomerAsn", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerAsnDetail_MasterID", - table: "Store_CustomerAsnDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerAsnDetail_Number_ItemCode", - table: "Store_CustomerAsnDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerReturnNote_Number_Company", - table: "Store_CustomerReturnNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerReturnNoteDetail_MasterID", - table: "Store_CustomerReturnNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerReturnNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_CustomerReturnNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverNote_Company_Number", - table: "Store_DeliverNote", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverNoteDetail_MasterID", - table: "Store_DeliverNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_DeliverNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverPlan_Number_Company", - table: "Store_DeliverPlan", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverPlanDetail_MasterID", - table: "Store_DeliverPlanDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverPlanDetail_Number_SoNumber_SoLine", - table: "Store_DeliverPlanDetail", - columns: new[] { "Number", "SoNumber", "SoLine" }, - unique: true, - filter: "[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverRequest_Company_Number", - table: "Store_DeliverRequest", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverRequestDetail_MasterID", - table: "Store_DeliverRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverRequestDetail_Number_ItemCode_ExpiredTime_ToLocationCode", - table: "Store_DeliverRequestDetail", - columns: new[] { "Number", "ItemCode", "ExpiredTime", "ToLocationCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectAbnormalNote_Number_Company", - table: "Store_InspectAbnormalNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectAbnormalNoteDetail_MasterID", - table: "Store_InspectAbnormalNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectAbnormalNoteDetail_Number_PackingCode", - table: "Store_InspectAbnormalNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectNote_Number_Company", - table: "Store_InspectNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectNoteDetail_MasterID", - table: "Store_InspectNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectNoteDetail_Number_PackingCode", - table: "Store_InspectNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectNoteSummaryDetail_MasterID", - table: "Store_InspectNoteSummaryDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectNoteSummaryDetail_Number_ItemCode", - table: "Store_InspectNoteSummaryDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectRequest_Number_Company", - table: "Store_InspectRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectRequestDetail_MasterID", - table: "Store_InspectRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectRequestDetail_Number_PackingCode", - table: "Store_InspectRequestDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectRequestSummaryDetail_MasterID", - table: "Store_InspectRequestSummaryDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectRequestSummaryDetail_Number_ItemCode_Lot", - table: "Store_InspectRequestSummaryDetail", - columns: new[] { "Number", "ItemCode", "Lot" }, - unique: true, - filter: "[Lot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_InventoryTransferNote_Number_Company", - table: "Store_InventoryTransferNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InventoryTransferNoteDetail_MasterID", - table: "Store_InventoryTransferNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_InventoryTransferNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_InventoryTransferNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_IsolationNote_Number_Company", - table: "Store_IsolationNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_IsolationNoteDetail_FromPackingCode", - table: "Store_IsolationNoteDetail", - column: "FromPackingCode"); - - migrationBuilder.CreateIndex( - name: "IX_Store_IsolationNoteDetail_MasterID", - table: "Store_IsolationNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_IsolationNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_IsolationNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_IssueNote_Number_Company", - table: "Store_IssueNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_IssueNoteDetail_FromPackingCode", - table: "Store_IssueNoteDetail", - column: "FromPackingCode"); - - migrationBuilder.CreateIndex( - name: "IX_Store_IssueNoteDetail_MasterID", - table: "Store_IssueNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_IssueNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_IssueNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ItemTransformNote_Number_Company", - table: "Store_ItemTransformNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ItemTransformNoteDetail_MasterID", - table: "Store_ItemTransformNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ItemTransformNoteDetail_Number_FromPackingCode_FromStatus_ToPackingCode_ToStatus", - table: "Store_ItemTransformNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ItemTransformRequest_Number_Company", - table: "Store_ItemTransformRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ItemTransformRequestDetail_MasterID", - table: "Store_ItemTransformRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ItemTransformRequestDetail_Number_FromPackingCode_FromStatus_ToPackingCode_ToStatus", - table: "Store_ItemTransformRequestDetail", - columns: new[] { "Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_JisDeliverNote_Company_Number", - table: "Store_JisDeliverNote", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_JisDeliverNoteDetail_MasterID", - table: "Store_JisDeliverNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_JisDeliverNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_JisDeliverNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_JisProductReceiptNote_Company_Number", - table: "Store_JisProductReceiptNote", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_JisProductReceiptNoteDetail_MasterID", - table: "Store_JisProductReceiptNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_JisProductReceiptNoteDetail_Number_PackingCode", - table: "Store_JisProductReceiptNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_MaterialRequest_Company_Number", - table: "Store_MaterialRequest", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_MaterialRequestDetail_ItemCode", - table: "Store_MaterialRequestDetail", - column: "ItemCode"); - - migrationBuilder.CreateIndex( - name: "IX_Store_MaterialRequestDetail_MasterID", - table: "Store_MaterialRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_MaterialRequestDetail_Number_ItemCode_ToLocationCode", - table: "Store_MaterialRequestDetail", - columns: new[] { "Number", "ItemCode", "ToLocationCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_OfflineSettlementNote_Number_Company", - table: "Store_OfflineSettlementNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_OfflineSettlementNoteDetail_MasterID", - table: "Store_OfflineSettlementNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_OfflineSettlementNoteDetail_Number", - table: "Store_OfflineSettlementNoteDetail", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PreparationPlan_Number_Company", - table: "Store_PreparationPlan", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PreparationPlanDetail_MasterID", - table: "Store_PreparationPlanDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PreparationPlanDetail_Number_ItemCode", - table: "Store_PreparationPlanDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionPlan_Number_Company", - table: "Store_ProductionPlan", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionPlanDetail_MasterID", - table: "Store_ProductionPlanDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionPlanDetail_Number_ItemCode", - table: "Store_ProductionPlanDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnNote_Number_Company", - table: "Store_ProductionReturnNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnNoteDetail_MasterID", - table: "Store_ProductionReturnNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_ProductionReturnNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnRequest_Company_Number", - table: "Store_ProductionReturnRequest", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnRequestDetail_ItemCode", - table: "Store_ProductionReturnRequestDetail", - column: "ItemCode"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnRequestDetail_MasterID", - table: "Store_ProductionReturnRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnRequestDetail_Number_ItemCode_LocationCode", - table: "Store_ProductionReturnRequestDetail", - columns: new[] { "Number", "ItemCode", "LocationCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductL7PartsNote_Company_Number", - table: "Store_ProductL7PartsNote", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductL7PartsNoteDetail_MasterID", - table: "Store_ProductL7PartsNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductL7PartsNoteDetail_Number_ProductNo_Position_Configuration_L7Part", - table: "Store_ProductL7PartsNoteDetail", - columns: new[] { "Number", "ProductNo", "Position", "Configuration", "L7Part" }, - unique: true, - filter: "[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptNote_Company_Number", - table: "Store_ProductReceiptNote", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptNoteDetail_MasterID", - table: "Store_ProductReceiptNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptNoteDetail_Number_PackingCode", - table: "Store_ProductReceiptNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptRequest_Number_Company", - table: "Store_ProductReceiptRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptRequestDetail_MasterID", - table: "Store_ProductReceiptRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptRequestDetail_Number_ItemCode", - table: "Store_ProductReceiptRequestDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleNote_Number_Company", - table: "Store_ProductRecycleNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleNoteDetail_MasterID", - table: "Store_ProductRecycleNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleNoteDetail_Number_ItemCode", - table: "Store_ProductRecycleNoteDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleRequest_Number_Company", - table: "Store_ProductRecycleRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleRequestDetail_MasterID", - table: "Store_ProductRecycleRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleRequestDetail_Number_ItemCode", - table: "Store_ProductRecycleRequestDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseOrder_Number_Company", - table: "Store_PurchaseOrder", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseOrderDetail_ItemCode_Number_PoLine", - table: "Store_PurchaseOrderDetail", - columns: new[] { "ItemCode", "Number", "PoLine" }, - unique: true, - filter: "[PoLine] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseOrderDetail_MasterID", - table: "Store_PurchaseOrderDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptNote_Number_Company", - table: "Store_PurchaseReceiptNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptNote_SupplierCode", - table: "Store_PurchaseReceiptNote", - column: "SupplierCode"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptNoteDetail_MasterID", - table: "Store_PurchaseReceiptNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReturnNote_Number_Company", - table: "Store_PurchaseReturnNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReturnNoteDetail_MasterID", - table: "Store_PurchaseReturnNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReturnNoteDetail_Number_PackingCode", - table: "Store_PurchaseReturnNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReturnRequest_Number_Company", - table: "Store_PurchaseReturnRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReturnRequestDetail_MasterID", - table: "Store_PurchaseReturnRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReturnRequestDetail_Number_PackingCode", - table: "Store_PurchaseReturnRequestDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayNote_Number_Company", - table: "Store_PutawayNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayNoteDetail_MasterID", - table: "Store_PutawayNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_PutawayNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayRequest_Number_Company", - table: "Store_PutawayRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayRequestDetail_MasterID", - table: "Store_PutawayRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ReceiptAbnormalNote_AsnNumber_Number_Company_SupplierCode_ReceiptNumber", - table: "Store_ReceiptAbnormalNote", - columns: new[] { "AsnNumber", "Number", "Company", "SupplierCode", "ReceiptNumber" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ReceiptAbnormalNote_SupplierCode", - table: "Store_ReceiptAbnormalNote", - column: "SupplierCode"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ReceiptAbnormalNoteDetail_MasterID", - table: "Store_ReceiptAbnormalNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ReceiptAbnormalNoteDetail_Number_PackingCode_ReceiptNumber", - table: "Store_ReceiptAbnormalNoteDetail", - columns: new[] { "Number", "PackingCode", "ReceiptNumber" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_RecycledMaterialReceiptNote_Number_Company", - table: "Store_RecycledMaterialReceiptNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_RecycledMaterialReceiptNoteDetail_MasterID", - table: "Store_RecycledMaterialReceiptNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_RecycledMaterialReceiptNoteDetail_Number_PackingCode", - table: "Store_RecycledMaterialReceiptNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_SaleOrder_CustomerCode", - table: "Store_SaleOrder", - column: "CustomerCode"); - - migrationBuilder.CreateIndex( - name: "IX_Store_SaleOrder_Number_Company", - table: "Store_SaleOrder", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_SaleOrderDetail_MasterID", - table: "Store_SaleOrderDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_SaleOrderDetail_Number_SoLine_ItemCode", - table: "Store_SaleOrderDetail", - columns: new[] { "Number", "SoLine", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ScrapNote_Number_Company", - table: "Store_ScrapNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ScrapNoteDetail_MasterID", - table: "Store_ScrapNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ScrapNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_ScrapNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_SupplierAsn_Number_Company", - table: "Store_SupplierAsn", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_SupplierAsn_SupplierCode", - table: "Store_SupplierAsn", - column: "SupplierCode"); - - migrationBuilder.CreateIndex( - name: "IX_Store_SupplierAsnDetail_MasterID", - table: "Store_SupplierAsnDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_SupplierAsnDetail_Number_ItemCode_PackingCode", - table: "Store_SupplierAsnDetail", - columns: new[] { "Number", "ItemCode", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferNote_Number_Company", - table: "Store_TransferNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferNoteDetail_MasterID", - table: "Store_TransferNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode_FromStatus_ToStatus", - table: "Store_TransferNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferRequest_Number_Company", - table: "Store_TransferRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferRequestDetail_MasterID", - table: "Store_TransferRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferRequestDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode_FromStatus_ToStatus", - table: "Store_TransferRequestDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueNote_Number_Company", - table: "Store_UnplannedIssueNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueNoteDetail_MasterID", - table: "Store_UnplannedIssueNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueNoteDetail_Number_PackingCode", - table: "Store_UnplannedIssueNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueRequest_Company_Number", - table: "Store_UnplannedIssueRequest", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueRequestDetail_MasterID", - table: "Store_UnplannedIssueRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueRequestDetail_Number_ItemCode", - table: "Store_UnplannedIssueRequestDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptNote_Number_Company", - table: "Store_UnplannedReceiptNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptNoteDetail_MasterID", - table: "Store_UnplannedReceiptNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptNoteDetail_Number_PackingCode", - table: "Store_UnplannedReceiptNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptRequest_Company_Number", - table: "Store_UnplannedReceiptRequest", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptRequestDetail_MasterID", - table: "Store_UnplannedReceiptRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptRequestDetail_Number_ItemCode", - table: "Store_UnplannedReceiptRequestDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_WarehouseTransferNote_Number_Company", - table: "Store_WarehouseTransferNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_WarehouseTransferNoteDetail_MasterID", - table: "Store_WarehouseTransferNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_WarehouseTransferNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_WarehouseTransferNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_WorkOrder_Number_Company", - table: "Store_WorkOrder", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_WorkOrderDetail_MasterID", - table: "Store_WorkOrderDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_WorkOrderDetail_Number_ItemCode", - table: "Store_WorkOrderDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropTable( - name: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_ContainerBindNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_CountNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_CountPlanDetail"); - - migrationBuilder.DropTable( - name: "Store_CustomerAsnDetail"); - - migrationBuilder.DropTable( - name: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_DeliverNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_DeliverPlanDetail"); - - migrationBuilder.DropTable( - name: "Store_DeliverRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_ExchangeData"); - - migrationBuilder.DropTable( - name: "Store_InspectAbnormalNoteDetailPhoto"); - - migrationBuilder.DropTable( - name: "Store_InspectNoteDetailPhoto"); - - migrationBuilder.DropTable( - name: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropTable( - name: "Store_InspectRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropTable( - name: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_IsolationNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_IssueNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_MaterialRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_PreparationPlanDetail"); - - migrationBuilder.DropTable( - name: "Store_ProductionPlanDetail"); - - migrationBuilder.DropTable( - name: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_ProductL7PartsNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropTable( - name: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_PutawayNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_PutawayRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_ReceiptAbnormalNotePhoto"); - - migrationBuilder.DropTable( - name: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_SaleOrderDetail"); - - migrationBuilder.DropTable( - name: "Store_ScrapNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_SupplierAsnDetail"); - - migrationBuilder.DropTable( - name: "Store_TransferNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_TransferRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_WorkOrderDetail"); - - migrationBuilder.DropTable( - name: "Store_PurchaseReceiptRequest"); - - migrationBuilder.DropTable( - name: "Store_BackFlushNote"); - - migrationBuilder.DropTable( - name: "Store_ContainerBindNote"); - - migrationBuilder.DropTable( - name: "Store_CountAdjustNote"); - - migrationBuilder.DropTable( - name: "Store_CountNote"); - - migrationBuilder.DropTable( - name: "Store_CountPlan"); - - migrationBuilder.DropTable( - name: "Store_CustomerAsn"); - - migrationBuilder.DropTable( - name: "Store_CustomerReturnNote"); - - migrationBuilder.DropTable( - name: "Store_DeliverNote"); - - migrationBuilder.DropTable( - name: "Store_DeliverPlan"); - - migrationBuilder.DropTable( - name: "Store_DeliverRequest"); - - migrationBuilder.DropTable( - name: "Store_InspectAbnormalNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_InspectNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_InspectRequest"); - - migrationBuilder.DropTable( - name: "Store_InventoryTransferNote"); - - migrationBuilder.DropTable( - name: "Store_IsolationNote"); - - migrationBuilder.DropTable( - name: "Store_IssueNote"); - - migrationBuilder.DropTable( - name: "Store_ItemTransformNote"); - - migrationBuilder.DropTable( - name: "Store_ItemTransformRequest"); - - migrationBuilder.DropTable( - name: "Store_JisDeliverNote"); - - migrationBuilder.DropTable( - name: "Store_JisProductReceiptNote"); - - migrationBuilder.DropTable( - name: "Store_MaterialRequest"); - - migrationBuilder.DropTable( - name: "Store_OfflineSettlementNote"); - - migrationBuilder.DropTable( - name: "Store_PreparationPlan"); - - migrationBuilder.DropTable( - name: "Store_ProductionPlan"); - - migrationBuilder.DropTable( - name: "Store_ProductionReturnNote"); - - migrationBuilder.DropTable( - name: "Store_ProductionReturnRequest"); - - migrationBuilder.DropTable( - name: "Store_ProductL7PartsNote"); - - migrationBuilder.DropTable( - name: "Store_ProductReceiptNote"); - - migrationBuilder.DropTable( - name: "Store_ProductReceiptRequest"); - - migrationBuilder.DropTable( - name: "Store_ProductRecycleNote"); - - migrationBuilder.DropTable( - name: "Store_ProductRecycleRequest"); - - migrationBuilder.DropTable( - name: "Store_PurchaseOrder"); - - migrationBuilder.DropTable( - name: "Store_PurchaseReceiptNote"); - - migrationBuilder.DropTable( - name: "Store_PurchaseReturnNote"); - - migrationBuilder.DropTable( - name: "Store_PurchaseReturnRequest"); - - migrationBuilder.DropTable( - name: "Store_PutawayNote"); - - migrationBuilder.DropTable( - name: "Store_PutawayRequest"); - - migrationBuilder.DropTable( - name: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_RecycledMaterialReceiptNote"); - - migrationBuilder.DropTable( - name: "Store_SaleOrder"); - - migrationBuilder.DropTable( - name: "Store_ScrapNote"); - - migrationBuilder.DropTable( - name: "Store_SupplierAsn"); - - migrationBuilder.DropTable( - name: "Store_TransferNote"); - - migrationBuilder.DropTable( - name: "Store_TransferRequest"); - - migrationBuilder.DropTable( - name: "Store_UnplannedIssueNote"); - - migrationBuilder.DropTable( - name: "Store_UnplannedIssueRequest"); - - migrationBuilder.DropTable( - name: "Store_UnplannedReceiptNote"); - - migrationBuilder.DropTable( - name: "Store_UnplannedReceiptRequest"); - - migrationBuilder.DropTable( - name: "Store_WarehouseTransferNote"); - - migrationBuilder.DropTable( - name: "Store_WorkOrder"); - - migrationBuilder.DropTable( - name: "Store_InspectAbnormalNote"); - - migrationBuilder.DropTable( - name: "Store_InspectNote"); - - migrationBuilder.DropTable( - name: "Store_ReceiptAbnormalNote"); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230104034259_RemoveCompany.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230104034259_RemoveCompany.Designer.cs deleted file mode 100644 index b41415cc2..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230104034259_RemoveCompany.Designer.cs +++ /dev/null @@ -1,19700 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230104034259_RemoveCompany")] - partial class RemoveCompany - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("Relational:MaxIdentifierLength", 128) - .HasAnnotation("ProductVersion", "5.0.17") - .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasColumnType("nvarchar(450)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RequestType") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint") - .HasAnnotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveUom") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RawLocation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique() - .HasFilter("[LocationCode] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("HandledContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledLot") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("RecommendContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendLot") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreateType") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "AuditCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "FirstCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "RepeatCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.Navigation("AuditCount"); - - b.Navigation("Batch"); - - b.Navigation("FirstCount"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RepeatCount"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "AuditCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "FirstCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "RepeatCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.Navigation("AuditCount"); - - b.Navigation("Batch"); - - b.Navigation("FirstCount"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RepeatCount"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("CustomerAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnId"); - - b1.ToTable("Store_CustomerAsn"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CustomerAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CustomerAsnId"); - - b1.ToTable("Store_CustomerAsn"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnId"); - }); - - b.Navigation("Contacts"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteId"); - - b1.ToTable("Store_DeliverNote"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteId"); - }); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("InspectAbnormalNoteDetailId", "PhotoID"); - - b1.ToTable("Store_InspectAbnormalNoteDetailPhoto"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Photos"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "InspectUser", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("InspectNoteDetailId", "PhotoID"); - - b1.ToTable("Store_InspectNoteDetailPhoto"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InspectUser"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Photos"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "InspectUser", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InspectUser"); - - b.Navigation("Item"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "FromQty", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ToQty", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("FromQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - - b.Navigation("ToQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "FromQty", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ToQty", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("FromQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - - b.Navigation("ToQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductL7PartsNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductL7PartsNoteDetailId"); - - b1.ToTable("Store_ProductL7PartsNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductL7PartsNoteDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ProductItem", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ProductItem"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "RawLocation", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("RawLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PlanQty", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("PlanQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("PurchaseOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderId"); - - b1.ToTable("Store_PurchaseOrder"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "HandledBatch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "RecommendBatch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "HandledLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "RecommendLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "HandledQty", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "RecommendQty", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("HandledBatch"); - - b.Navigation("HandledLocation"); - - b.Navigation("HandledQty"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("RecommendBatch"); - - b.Navigation("RecommendLocation"); - - b.Navigation("RecommendQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("ReceiptAbnormalNoteDetailId", "PhotoID"); - - b1.ToTable("Store_ReceiptAbnormalNotePhoto"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Photos"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("SaleOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderId"); - - b1.ToTable("Store_SaleOrder"); - - b1.WithOwner() - .HasForeignKey("SaleOrderId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "CustomerPack", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.Navigation("CustomerPack"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("SupplierAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnId"); - - b1.ToTable("Store_SupplierAsn"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "RawQty", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("RawQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230104034259_RemoveCompany.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230104034259_RemoveCompany.cs deleted file mode 100644 index a0b55c93c..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230104034259_RemoveCompany.cs +++ /dev/null @@ -1,14501 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class RemoveCompany : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Store_WorkOrder_Number_Company", - table: "Store_WorkOrder"); - - migrationBuilder.DropIndex( - name: "IX_Store_WarehouseTransferNote_Number_Company", - table: "Store_WarehouseTransferNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedReceiptRequestDetail_Number_ItemCode", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedReceiptRequest_Company_Number", - table: "Store_UnplannedReceiptRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedReceiptNoteDetail_Number_PackingCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedReceiptNote_Number_Company", - table: "Store_UnplannedReceiptNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedIssueRequestDetail_Number_ItemCode", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedIssueRequest_Company_Number", - table: "Store_UnplannedIssueRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedIssueNoteDetail_Number_PackingCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedIssueNote_Number_Company", - table: "Store_UnplannedIssueNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_TransferRequestDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode_FromStatus_ToStatus", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_TransferRequest_Number_Company", - table: "Store_TransferRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_TransferNote_Number_Company", - table: "Store_TransferNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_SupplierAsn_Number_Company", - table: "Store_SupplierAsn"); - - migrationBuilder.DropIndex( - name: "IX_Store_ScrapNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_ScrapNote_Number_Company", - table: "Store_ScrapNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_SaleOrder_Number_Company", - table: "Store_SaleOrder"); - - migrationBuilder.DropIndex( - name: "IX_Store_RecycledMaterialReceiptNote_Number_Company", - table: "Store_RecycledMaterialReceiptNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ReceiptAbnormalNote_AsnNumber_Number_Company_SupplierCode_ReceiptNumber", - table: "Store_ReceiptAbnormalNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_PutawayRequest_Number_Company", - table: "Store_PutawayRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_PutawayNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_PutawayNote_Number_Company", - table: "Store_PutawayNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_PurchaseReturnRequest_Number_Company", - table: "Store_PurchaseReturnRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_PurchaseReturnNote_Number_Company", - table: "Store_PurchaseReturnNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_PurchaseReceiptNote_Number_Company", - table: "Store_PurchaseReceiptNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_PurchaseOrder_Number_Company", - table: "Store_PurchaseOrder"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductRecycleRequest_Number_Company", - table: "Store_ProductRecycleRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductRecycleNote_Number_Company", - table: "Store_ProductRecycleNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductReceiptRequestDetail_Number_ItemCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductReceiptRequest_Number_Company", - table: "Store_ProductReceiptRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductReceiptNoteDetail_Number_PackingCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductReceiptNote_Company_Number", - table: "Store_ProductReceiptNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductL7PartsNote_Company_Number", - table: "Store_ProductL7PartsNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductionReturnRequest_Company_Number", - table: "Store_ProductionReturnRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductionReturnNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductionReturnNote_Number_Company", - table: "Store_ProductionReturnNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductionPlan_Number_Company", - table: "Store_ProductionPlan"); - - migrationBuilder.DropIndex( - name: "IX_Store_PreparationPlan_Number_Company", - table: "Store_PreparationPlan"); - - migrationBuilder.DropIndex( - name: "IX_Store_OfflineSettlementNote_Number_Company", - table: "Store_OfflineSettlementNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_MaterialRequest_Company_Number", - table: "Store_MaterialRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_JisProductReceiptNote_Company_Number", - table: "Store_JisProductReceiptNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_JisDeliverNote_Company_Number", - table: "Store_JisDeliverNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ItemTransformRequest_Number_Company", - table: "Store_ItemTransformRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_ItemTransformNote_Number_Company", - table: "Store_ItemTransformNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_IssueNote_Number_Company", - table: "Store_IssueNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_IsolationNote_Number_Company", - table: "Store_IsolationNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_InventoryTransferNote_Number_Company", - table: "Store_InventoryTransferNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_InspectRequest_Number_Company", - table: "Store_InspectRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_InspectNote_Number_Company", - table: "Store_InspectNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_InspectAbnormalNote_Number_Company", - table: "Store_InspectAbnormalNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_DeliverRequestDetail_Number_ItemCode_ExpiredTime_ToLocationCode", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_DeliverRequest_Company_Number", - table: "Store_DeliverRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_DeliverPlan_Number_Company", - table: "Store_DeliverPlan"); - - migrationBuilder.DropIndex( - name: "IX_Store_DeliverNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_DeliverNote_Company_Number", - table: "Store_DeliverNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_CustomerReturnNote_Number_Company", - table: "Store_CustomerReturnNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_CustomerAsn_Number_Company", - table: "Store_CustomerAsn"); - - migrationBuilder.DropIndex( - name: "IX_Store_CountPlan_Number_Company", - table: "Store_CountPlan"); - - migrationBuilder.DropIndex( - name: "IX_Store_CountNote_Number_Company", - table: "Store_CountNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_CountAdjustNoteDetail_Number_CountLabel", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_CountAdjustNote_Number_Company", - table: "Store_CountAdjustNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ContainerBindNote_Number_Company", - table: "Store_ContainerBindNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_BackFlushNote_Number_Company", - table: "Store_BackFlushNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_PurchaseReceiptRequest_Number_Company", - table: "Store_PurchaseReceiptRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_WorkOrder"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_WarehouseTransferNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_UnplannedReceiptRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_UnplannedReceiptNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_UnplannedIssueRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_UnplannedIssueNote"); - - migrationBuilder.DropColumn( - name: "InTransitLocation", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_TransferRequest"); - - migrationBuilder.DropColumn( - name: "TransferType", - table: "Store_TransferRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_TransferNote"); - - migrationBuilder.DropColumn( - name: "TransferType", - table: "Store_TransferNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_SupplierAsn"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ScrapNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_SaleOrder"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_RecycledMaterialReceiptNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ReceiptAbnormalNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_PutawayRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_PutawayNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_PurchaseReturnRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_PurchaseReturnNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_PurchaseReceiptNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_PurchaseOrder"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ProductRecycleRequest"); - - migrationBuilder.DropColumn( - name: "BomVersion", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "RawLocationCode", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "RawLocation_Area", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "RawLocation_ErpCode", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "RawLocation_Group", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ProductRecycleNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ProductReceiptRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ProductReceiptNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ProductL7PartsNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ProductionReturnRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ProductionReturnNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ProductionPlan"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_PreparationPlan"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_OfflineSettlementNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_MaterialRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_JisProductReceiptNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_JisDeliverNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ItemTransformRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ItemTransformNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_IssueNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_IsolationNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_InventoryTransferNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_InspectRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_InspectNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_InspectAbnormalNote"); - - migrationBuilder.DropColumn( - name: "ExpiredTime", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationCode", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_DeliverRequest"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_DeliverPlan"); - - migrationBuilder.DropColumn( - name: "DeliverTime", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ExpiredTime", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_CustomerReturnNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_CustomerAsn"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_CountPlan"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_CountNote"); - - migrationBuilder.DropColumn( - name: "JobNumber", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_CountAdjustNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_ContainerBindNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_BackFlushNote"); - - migrationBuilder.DropColumn( - name: "Company", - table: "Store_PurchaseReceiptRequest"); - - migrationBuilder.RenameColumn( - name: "NeedInTransitLocation", - table: "Store_TransferRequest", - newName: "UseOnTheWayLocation"); - - migrationBuilder.RenameColumn( - name: "InTransitLocation", - table: "Store_TransferNoteDetail", - newName: "OnTheWayLocationCode"); - - migrationBuilder.RenameColumn( - name: "NeedInTransitLocation", - table: "Store_TransferNote", - newName: "UseOnTheWayLocation"); - - migrationBuilder.RenameColumn( - name: "Adjusted", - table: "Store_TransferNote", - newName: "Confirmed"); - - migrationBuilder.RenameColumn( - name: "LocationErpCode", - table: "Store_SupplierAsnDetail", - newName: "RecommendErpCode"); - - migrationBuilder.RenameColumn( - name: "PutawayType", - table: "Store_PutawayRequest", - newName: "Type"); - - migrationBuilder.RenameColumn( - name: "PutawayJobType", - table: "Store_PutawayRequest", - newName: "PutawayMode"); - - migrationBuilder.RenameColumn( - name: "PRRequestNumber", - table: "Store_ProductRecycleNote", - newName: "RequestNumber"); - - migrationBuilder.RenameColumn( - name: "Location_Group", - table: "Store_MaterialRequestDetail", - newName: "ToLocation_Group"); - - migrationBuilder.RenameColumn( - name: "Location_ErpCode", - table: "Store_MaterialRequestDetail", - newName: "ToLocation_ErpCode"); - - migrationBuilder.RenameColumn( - name: "Location_Area", - table: "Store_MaterialRequestDetail", - newName: "ToLocation_Area"); - - migrationBuilder.RenameColumn( - name: "DeliverType", - table: "Store_DeliverRequest", - newName: "DeliverRequestType"); - - migrationBuilder.RenameColumn( - name: "Customer", - table: "Store_DeliverNote", - newName: "CustomerCode"); - - migrationBuilder.RenameColumn( - name: "Type", - table: "Store_CountAdjustNoteDetail", - newName: "TransInOut"); - - migrationBuilder.AlterColumn( - name: "RawQty_Uom", - table: "Store_WorkOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_WorkOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_WorkOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_WorkOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_WorkOrder", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_WorkOrder", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_TransferRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_TransferRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromPackingCode", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Type", - table: "Store_TransferRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_TransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_TransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ConfirmTime", - table: "Store_TransferNote", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "Type", - table: "Store_TransferNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_SupplierAsnDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_SupplierAsnDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "PlanUserCode", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Phone", - table: "Store_SupplierAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Name", - table: "Store_SupplierAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Email", - table: "Store_SupplierAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "CreateType", - table: "Store_SupplierAsn", - type: "int", - nullable: false, - defaultValue: 0); - - migrationBuilder.AddColumn( - name: "PlanUserCode", - table: "Store_SupplierAsn", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ScrapNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ScrapNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLot", - table: "Store_ScrapNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ScrapRequestNumber", - table: "Store_ScrapNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_SaleOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_SaleOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "CustomerPack_PackUom", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Phone", - table: "Store_SaleOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Name", - table: "Store_SaleOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Email", - table: "Store_SaleOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PutawayRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PutawayRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InventoryQty_Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "FromContainerCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocationCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLot", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromPackingCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromStatus", - table: "Store_PutawayRequestDetail", - type: "int", - nullable: false, - defaultValue: 0); - - migrationBuilder.AddColumn( - name: "FromWarehouseCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "HandledBatch_ArriveDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledBatch_ExpireDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledBatch_ProduceDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledBatch_SupplierBatch", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLocationCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLocation_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLocation_ErpCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLocation_Group", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledQty_Qty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledQty_Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendBatch_ArriveDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendBatch_ExpireDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendBatch_ProduceDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendBatch_SupplierBatch", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLocationCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLocation_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLocation_ErpCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLocation_Group", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendQty_Qty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendQty_Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToContainerCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocationCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLot", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToPackingCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToStatus", - table: "Store_PutawayRequestDetail", - type: "int", - nullable: false, - defaultValue: 0); - - migrationBuilder.AddColumn( - name: "ToWarehouseCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "RequestNumber", - table: "Store_PutawayRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "ToPackingCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PutawayNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PutawayNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "JobNumber", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_PutawayNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Worker", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Type", - table: "Store_PutawayNote", - type: "int", - nullable: false, - defaultValue: 0); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "RecommendErpCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "PutAwayQty", - table: "Store_PurchaseOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "ReceivedQty", - table: "Store_PurchaseOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "ReturnedQty", - table: "Store_PurchaseOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "ShippedQty", - table: "Store_PurchaseOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Contacts_Phone", - table: "Store_PurchaseOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Name", - table: "Store_PurchaseOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Email", - table: "Store_PurchaseOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RawLocation_Group", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RawLocation_ErpCode", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RawLocation_Area", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Shift", - table: "Store_ProductRecycleRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Workshop", - table: "Store_ProductRecycleRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Shift", - table: "Store_ProductRecycleNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Workshop", - table: "Store_ProductRecycleNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "LocationCode", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RawArea", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ReturnQty", - table: "Store_ProductReceiptRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Workshop", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Team", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Shift", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProdLine", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Type", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RawLocation", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProdLine", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "RawArea", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ReturnQty", - table: "Store_ProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "WorkShop", - table: "Store_ProductReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "ProductReceiptRequestNumber", - table: "Store_ProductReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Type", - table: "Store_ProductReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToPackingCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "PlanQty_Uom", - table: "Store_ProductionPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductionPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductionPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductionPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductionPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PreparationPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PreparationPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PreparationPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PreparationPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PreparationPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_MaterialRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_MaterialRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Type", - table: "Store_MaterialRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "UseOnTheWayLocation", - table: "Store_MaterialRequest", - type: "bit", - nullable: false, - defaultValue: false); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToQty_Uom", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Name", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Desc2", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Desc1", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToBatch_SupplierBatch", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromQty_Uom", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromBatch_SupplierBatch", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToQty_Uom", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Name", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Desc2", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Desc1", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToBatch_SupplierBatch", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromQty_Uom", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromBatch_SupplierBatch", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_IssueNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_IssueNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "OnTheWayLocationCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ConfirmTime", - table: "Store_IssueNote", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "Confirmed", - table: "Store_IssueNote", - type: "bit", - nullable: false, - defaultValue: false); - - migrationBuilder.AddColumn( - name: "RequestNumber", - table: "Store_IssueNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RequestType", - table: "Store_IssueNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "UseOnTheWayLocation", - table: "Store_IssueNote", - type: "bit", - nullable: false, - defaultValue: false); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_IsolationNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_IsolationNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InspectRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InspectRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Phone", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Name", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Email", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InspectNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InspectNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Phone", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Name", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Email", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_DeliverRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_DeliverRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_DeliverRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_DeliverRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_DeliverRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "AreaCode", - table: "Store_DeliverRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "DeliverPlanNumber", - table: "Store_DeliverRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "CustomerAddressCode", - table: "Store_DeliverRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "DeliverTime", - table: "Store_DeliverRequest", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_DeliverPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_DeliverPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_DeliverPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_DeliverPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_DeliverPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToPackingCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLot", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_DeliverNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_DeliverNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromPackingCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLot", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ExtraProperties", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "CustomerAddressCode", - table: "Store_DeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "DeliverPlanNumber", - table: "Store_DeliverNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "DeliverRequestNumber", - table: "Store_DeliverNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "DeliverRequestType", - table: "Store_DeliverNote", - type: "int", - nullable: false, - defaultValue: 0); - - migrationBuilder.AddColumn( - name: "DeliverTime", - table: "Store_DeliverNote", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "ToLocationCode", - table: "Store_DeliverNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_DeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_DeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_DeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_CustomerAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_CustomerAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_CustomerAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_CustomerAsnDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_CustomerAsnDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Phone", - table: "Store_CustomerAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Name", - table: "Store_CustomerAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Email", - table: "Store_CustomerAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RepeatCount_Operator", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RepeatCount_Description", - table: "Store_CountPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_CountPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_CountPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InventoryQty_Uom", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FirstCount_Operator", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FirstCount_Description", - table: "Store_CountPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "AuditCount_Operator", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "AuditCount_Description", - table: "Store_CountPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "JsonInventoryStatus", - table: "Store_CountPlan", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "JsonItemCodes", - table: "Store_CountPlan", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "JsonLocationCodes", - table: "Store_CountPlan", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RequestType", - table: "Store_CountPlan", - type: "int", - nullable: false, - defaultValue: 0); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RepeatCount_Operator", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RepeatCount_Description", - table: "Store_CountNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_CountNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_CountNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InventoryQty_Uom", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FirstCount_Operator", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FirstCount_Description", - table: "Store_CountNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "AuditCount_Operator", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "AuditCount_Description", - table: "Store_CountNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InventoryQty_Uom", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "CountAdjustRequestNumber", - table: "Store_CountAdjustNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "IsAdjusted", - table: "Store_CountAdjustNote", - type: "bit", - nullable: false, - defaultValue: false); - - migrationBuilder.AddColumn( - name: "JobNumber", - table: "Store_CountAdjustNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Type", - table: "Store_CountAdjustNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_BackFlushNote", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_BackFlushNote", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "RecommendErpCode", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.CreateTable( - name: "Store_CountAdjustRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CountNoteNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CountPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CountAdjustRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_InventoryInitialNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InventoryInitialNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_NoOkConvertOkNote", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_NoOkConvertOkNote", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_ProductRecycleMaterialDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductItem_Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductItem_Desc1 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ProductItem_Desc2 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ProductLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Location_Area = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ProductRecycleMaterialDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ProductRecycleMaterialDetail_Store_ProductRecycleNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_ProductRecycleNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ScrapRequest", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ActiveDate = table.Column(type: "datetime2", nullable: false), - AutoSubmit = table.Column(type: "bit", nullable: false), - AutoAgree = table.Column(type: "bit", nullable: false), - AutoHandle = table.Column(type: "bit", nullable: false), - AutoCompleteJob = table.Column(type: "bit", nullable: false), - DirectCreateNote = table.Column(type: "bit", nullable: false), - RequestStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ScrapRequest", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Store_CountAdjustRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), - InventoryQty_Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - InventoryQty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - CountQty = table.Column(type: "decimal(18,6)", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Location_Area = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_CountAdjustRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_CountAdjustRequestDetail_Store_CountAdjustRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_CountAdjustRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_InventoryInitialNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Location_Area = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Status = table.Column(type: "int", nullable: false), - Qty_Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InventoryInitialNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_InventoryInitialNoteDetail_Store_InventoryInitialNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_InventoryInitialNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_NoOkConvertOkNoteDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true), - FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), - ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), - FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - FromLot = table.Column(type: "nvarchar(max)", nullable: true), - ToLot = table.Column(type: "nvarchar(max)", nullable: true), - Batch_SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Batch_ArriveDate = table.Column(type: "datetime2", nullable: true), - Batch_ProduceDate = table.Column(type: "datetime2", nullable: true), - Batch_ExpireDate = table.Column(type: "datetime2", nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromLocation_Group = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromLocation_Area = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromLocation_ErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocation_Group = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocation_Area = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocation_ErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - FromStatus = table.Column(type: "int", nullable: false), - ToStatus = table.Column(type: "int", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_NoOkConvertOkNoteDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_NoOkConvertOkNoteDetail_Store_NoOkConvertOkNote_MasterID", - column: x => x.MasterID, - principalTable: "Store_NoOkConvertOkNote", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ScrapRequestDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReasonCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Location_Group = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Location_Area = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Location_ErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Item_Name = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Item_Desc1 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - Item_Desc2 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty_Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty_Qty = table.Column(type: "decimal(18,6)", nullable: true), - StdPack_PackUom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - StdPack_PackQty = table.Column(type: "decimal(18,6)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ScrapRequestDetail", x => x.Id); - table.ForeignKey( - name: "FK_Store_ScrapRequestDetail_Store_ScrapRequest_MasterID", - column: x => x.MasterID, - principalTable: "Store_ScrapRequest", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateIndex( - name: "IX_Store_WorkOrder_Number", - table: "Store_WorkOrder", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_WarehouseTransferNote_Number", - table: "Store_WarehouseTransferNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptRequestDetail_Number_PackingCode_ItemCode_Lot_Status", - table: "Store_UnplannedReceiptRequestDetail", - columns: new[] { "Number", "PackingCode", "ItemCode", "Lot", "Status" }, - unique: true, - filter: "[Lot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptRequest_Number", - table: "Store_UnplannedReceiptRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptNoteDetail_Number_PackingCode_ItemCode_Lot_Status", - table: "Store_UnplannedReceiptNoteDetail", - columns: new[] { "Number", "PackingCode", "ItemCode", "Lot", "Status" }, - unique: true, - filter: "[Lot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptNote_Number", - table: "Store_UnplannedReceiptNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueRequestDetail_Number_PackingCode_ItemCode_Lot_Status", - table: "Store_UnplannedIssueRequestDetail", - columns: new[] { "Number", "PackingCode", "ItemCode", "Lot", "Status" }, - unique: true, - filter: "[Lot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueRequest_Number", - table: "Store_UnplannedIssueRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueNoteDetail_Number_PackingCode_ItemCode_Lot_Status", - table: "Store_UnplannedIssueNoteDetail", - columns: new[] { "Number", "PackingCode", "ItemCode", "Lot", "Status" }, - unique: true, - filter: "[Lot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueNote_Number", - table: "Store_UnplannedIssueNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferRequest_Number", - table: "Store_TransferRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferNote_Number", - table: "Store_TransferNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_SupplierAsn_Number", - table: "Store_SupplierAsn", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ScrapNoteDetail_Number_ItemCode_FromPackingCode_FromLocationCode_ToLocationCode_FromLot_FromStatus", - table: "Store_ScrapNoteDetail", - columns: new[] { "Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ScrapNote_Number", - table: "Store_ScrapNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_SaleOrder_Number", - table: "Store_SaleOrder", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_RecycledMaterialReceiptNote_Number", - table: "Store_RecycledMaterialReceiptNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ReceiptAbnormalNote_AsnNumber_Number_SupplierCode_ReceiptNumber", - table: "Store_ReceiptAbnormalNote", - columns: new[] { "AsnNumber", "Number", "SupplierCode", "ReceiptNumber" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayRequest_Number", - table: "Store_PutawayRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode_ToPackingCode", - table: "Store_PutawayNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayNote_Number", - table: "Store_PutawayNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReturnRequest_Number", - table: "Store_PurchaseReturnRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReturnNote_Number", - table: "Store_PurchaseReturnNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptNote_Number", - table: "Store_PurchaseReceiptNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseOrder_Number", - table: "Store_PurchaseOrder", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleRequest_Number", - table: "Store_ProductRecycleRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleNote_Number", - table: "Store_ProductRecycleNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptRequestDetail_Number_ItemCode_LocationCode", - table: "Store_ProductReceiptRequestDetail", - columns: new[] { "Number", "ItemCode", "LocationCode" }, - unique: true, - filter: "[LocationCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptRequest_Number", - table: "Store_ProductReceiptRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptNoteDetail_Number_ItemCode_PackingCode_Lot_Status", - table: "Store_ProductReceiptNoteDetail", - columns: new[] { "Number", "ItemCode", "PackingCode", "Lot", "Status" }, - unique: true, - filter: "[Lot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptNote_Number", - table: "Store_ProductReceiptNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductL7PartsNote_Number", - table: "Store_ProductL7PartsNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnRequest_Number", - table: "Store_ProductionReturnRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnNoteDetail_Number_ItemCode_FromPackingCode_ToPackingCode_FromLocationCode_ToLocationCode", - table: "Store_ProductionReturnNoteDetail", - columns: new[] { "Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnNote_Number", - table: "Store_ProductionReturnNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionPlan_Number", - table: "Store_ProductionPlan", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PreparationPlan_Number", - table: "Store_PreparationPlan", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_OfflineSettlementNote_Number", - table: "Store_OfflineSettlementNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_MaterialRequest_Number", - table: "Store_MaterialRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_JisProductReceiptNote_Number", - table: "Store_JisProductReceiptNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_JisDeliverNote_Number", - table: "Store_JisDeliverNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ItemTransformRequest_Number", - table: "Store_ItemTransformRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ItemTransformNote_Number", - table: "Store_ItemTransformNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_IssueNote_Number", - table: "Store_IssueNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_IsolationNote_Number", - table: "Store_IsolationNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InventoryTransferNote_Number", - table: "Store_InventoryTransferNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectRequest_Number", - table: "Store_InspectRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectNote_Number", - table: "Store_InspectNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectAbnormalNote_Number", - table: "Store_InspectAbnormalNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverRequestDetail_Number_ItemCode", - table: "Store_DeliverRequestDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverRequest_Number", - table: "Store_DeliverRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverPlan_Number", - table: "Store_DeliverPlan", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverNoteDetail_Number_ItemCode_FromPackingCode_FromLot_FromLocationCode_ToLocationCode", - table: "Store_DeliverNoteDetail", - columns: new[] { "Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverNote_Number", - table: "Store_DeliverNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerReturnNote_Number", - table: "Store_CustomerReturnNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerAsn_Number", - table: "Store_CustomerAsn", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountPlan_Number", - table: "Store_CountPlan", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountNote_Number", - table: "Store_CountNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountAdjustNoteDetail_Number_CountLabel_ItemCode_LocationCode_Lot_Status_PackingCode", - table: "Store_CountAdjustNoteDetail", - columns: new[] { "Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode" }, - unique: true, - filter: "[Lot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountAdjustNote_Number", - table: "Store_CountAdjustNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ContainerBindNote_Number", - table: "Store_ContainerBindNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_BackFlushNote_Number", - table: "Store_BackFlushNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptRequest_Number", - table: "Store_PurchaseReceiptRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountAdjustRequest_Number", - table: "Store_CountAdjustRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountAdjustRequestDetail_MasterID", - table: "Store_CountAdjustRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountAdjustRequestDetail_Number_ItemCode_LocationCode_Lot_Status_PackingCode", - table: "Store_CountAdjustRequestDetail", - columns: new[] { "Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode" }, - unique: true, - filter: "[Lot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_InventoryInitialNote_Number", - table: "Store_InventoryInitialNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InventoryInitialNoteDetail_MasterID", - table: "Store_InventoryInitialNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_InventoryInitialNoteDetail_Number_PackingCode_ItemCode_Lot_Status", - table: "Store_InventoryInitialNoteDetail", - columns: new[] { "Number", "PackingCode", "ItemCode", "Lot", "Status" }, - unique: true, - filter: "[Lot] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_NoOkConvertOkNote_Number", - table: "Store_NoOkConvertOkNote", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_NoOkConvertOkNoteDetail_MasterID", - table: "Store_NoOkConvertOkNoteDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_NoOkConvertOkNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_NoOkConvertOkNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleMaterialDetail_MasterID", - table: "Store_ProductRecycleMaterialDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleMaterialDetail_Number_ProductItemCode_ItemCode", - table: "Store_ProductRecycleMaterialDetail", - columns: new[] { "Number", "ProductItemCode", "ItemCode" }); - - migrationBuilder.CreateIndex( - name: "IX_Store_ScrapRequest_Number", - table: "Store_ScrapRequest", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ScrapRequestDetail_MasterID", - table: "Store_ScrapRequestDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ScrapRequestDetail_Number_ItemCode_LocationCode", - table: "Store_ScrapRequestDetail", - columns: new[] { "Number", "ItemCode", "LocationCode" }, - unique: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropTable( - name: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropTable( - name: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropTable( - name: "Store_ScrapRequestDetail"); - - migrationBuilder.DropTable( - name: "Store_CountAdjustRequest"); - - migrationBuilder.DropTable( - name: "Store_InventoryInitialNote"); - - migrationBuilder.DropTable( - name: "Store_NoOkConvertOkNote"); - - migrationBuilder.DropTable( - name: "Store_ScrapRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_WorkOrder_Number", - table: "Store_WorkOrder"); - - migrationBuilder.DropIndex( - name: "IX_Store_WarehouseTransferNote_Number", - table: "Store_WarehouseTransferNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedReceiptRequestDetail_Number_PackingCode_ItemCode_Lot_Status", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedReceiptRequest_Number", - table: "Store_UnplannedReceiptRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedReceiptNoteDetail_Number_PackingCode_ItemCode_Lot_Status", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedReceiptNote_Number", - table: "Store_UnplannedReceiptNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedIssueRequestDetail_Number_PackingCode_ItemCode_Lot_Status", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedIssueRequest_Number", - table: "Store_UnplannedIssueRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedIssueNoteDetail_Number_PackingCode_ItemCode_Lot_Status", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_UnplannedIssueNote_Number", - table: "Store_UnplannedIssueNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_TransferRequest_Number", - table: "Store_TransferRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_TransferNote_Number", - table: "Store_TransferNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_SupplierAsn_Number", - table: "Store_SupplierAsn"); - - migrationBuilder.DropIndex( - name: "IX_Store_ScrapNoteDetail_Number_ItemCode_FromPackingCode_FromLocationCode_ToLocationCode_FromLot_FromStatus", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_ScrapNote_Number", - table: "Store_ScrapNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_SaleOrder_Number", - table: "Store_SaleOrder"); - - migrationBuilder.DropIndex( - name: "IX_Store_RecycledMaterialReceiptNote_Number", - table: "Store_RecycledMaterialReceiptNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ReceiptAbnormalNote_AsnNumber_Number_SupplierCode_ReceiptNumber", - table: "Store_ReceiptAbnormalNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_PutawayRequest_Number", - table: "Store_PutawayRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_PutawayNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode_ToPackingCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_PutawayNote_Number", - table: "Store_PutawayNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_PurchaseReturnRequest_Number", - table: "Store_PurchaseReturnRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_PurchaseReturnNote_Number", - table: "Store_PurchaseReturnNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_PurchaseReceiptNote_Number", - table: "Store_PurchaseReceiptNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_PurchaseOrder_Number", - table: "Store_PurchaseOrder"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductRecycleRequest_Number", - table: "Store_ProductRecycleRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductRecycleNote_Number", - table: "Store_ProductRecycleNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductReceiptRequestDetail_Number_ItemCode_LocationCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductReceiptRequest_Number", - table: "Store_ProductReceiptRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductReceiptNoteDetail_Number_ItemCode_PackingCode_Lot_Status", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductReceiptNote_Number", - table: "Store_ProductReceiptNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductL7PartsNote_Number", - table: "Store_ProductL7PartsNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductionReturnRequest_Number", - table: "Store_ProductionReturnRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductionReturnNoteDetail_Number_ItemCode_FromPackingCode_ToPackingCode_FromLocationCode_ToLocationCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductionReturnNote_Number", - table: "Store_ProductionReturnNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductionPlan_Number", - table: "Store_ProductionPlan"); - - migrationBuilder.DropIndex( - name: "IX_Store_PreparationPlan_Number", - table: "Store_PreparationPlan"); - - migrationBuilder.DropIndex( - name: "IX_Store_OfflineSettlementNote_Number", - table: "Store_OfflineSettlementNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_MaterialRequest_Number", - table: "Store_MaterialRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_JisProductReceiptNote_Number", - table: "Store_JisProductReceiptNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_JisDeliverNote_Number", - table: "Store_JisDeliverNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ItemTransformRequest_Number", - table: "Store_ItemTransformRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_ItemTransformNote_Number", - table: "Store_ItemTransformNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_IssueNote_Number", - table: "Store_IssueNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_IsolationNote_Number", - table: "Store_IsolationNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_InventoryTransferNote_Number", - table: "Store_InventoryTransferNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_InspectRequest_Number", - table: "Store_InspectRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_InspectNote_Number", - table: "Store_InspectNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_InspectAbnormalNote_Number", - table: "Store_InspectAbnormalNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_DeliverRequestDetail_Number_ItemCode", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_DeliverRequest_Number", - table: "Store_DeliverRequest"); - - migrationBuilder.DropIndex( - name: "IX_Store_DeliverPlan_Number", - table: "Store_DeliverPlan"); - - migrationBuilder.DropIndex( - name: "IX_Store_DeliverNoteDetail_Number_ItemCode_FromPackingCode_FromLot_FromLocationCode_ToLocationCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_DeliverNote_Number", - table: "Store_DeliverNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_CustomerReturnNote_Number", - table: "Store_CustomerReturnNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_CustomerAsn_Number", - table: "Store_CustomerAsn"); - - migrationBuilder.DropIndex( - name: "IX_Store_CountPlan_Number", - table: "Store_CountPlan"); - - migrationBuilder.DropIndex( - name: "IX_Store_CountNote_Number", - table: "Store_CountNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_CountAdjustNoteDetail_Number_CountLabel_ItemCode_LocationCode_Lot_Status_PackingCode", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_CountAdjustNote_Number", - table: "Store_CountAdjustNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_ContainerBindNote_Number", - table: "Store_ContainerBindNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_BackFlushNote_Number", - table: "Store_BackFlushNote"); - - migrationBuilder.DropIndex( - name: "IX_Store_PurchaseReceiptRequest_Number", - table: "Store_PurchaseReceiptRequest"); - - migrationBuilder.DropColumn( - name: "Type", - table: "Store_TransferRequest"); - - migrationBuilder.DropColumn( - name: "ConfirmTime", - table: "Store_TransferNote"); - - migrationBuilder.DropColumn( - name: "Type", - table: "Store_TransferNote"); - - migrationBuilder.DropColumn( - name: "PlanUserCode", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "CreateType", - table: "Store_SupplierAsn"); - - migrationBuilder.DropColumn( - name: "PlanUserCode", - table: "Store_SupplierAsn"); - - migrationBuilder.DropColumn( - name: "ScrapRequestNumber", - table: "Store_ScrapNote"); - - migrationBuilder.DropColumn( - name: "FromContainerCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLot", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromPackingCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromStatus", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWarehouseCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledBatch_ArriveDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledBatch_ExpireDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledBatch_ProduceDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledBatch_SupplierBatch", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledLocationCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledLocation_Area", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledLocation_ErpCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledLocation_Group", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty_Qty", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty_Uom", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendBatch_ArriveDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendBatch_ExpireDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendBatch_ProduceDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendBatch_SupplierBatch", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLocationCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLocation_Area", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLocation_ErpCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLocation_Group", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty_Qty", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty_Uom", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToContainerCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLot", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToPackingCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToStatus", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWarehouseCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RequestNumber", - table: "Store_PutawayRequest"); - - migrationBuilder.DropColumn( - name: "JobNumber", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "Worker", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "Type", - table: "Store_PutawayNote"); - - migrationBuilder.DropColumn( - name: "RecommendErpCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "PutAwayQty", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "ReceivedQty", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "ReturnedQty", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "ShippedQty", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "Shift", - table: "Store_ProductRecycleRequest"); - - migrationBuilder.DropColumn( - name: "Workshop", - table: "Store_ProductRecycleRequest"); - - migrationBuilder.DropColumn( - name: "Shift", - table: "Store_ProductRecycleNote"); - - migrationBuilder.DropColumn( - name: "Workshop", - table: "Store_ProductRecycleNote"); - - migrationBuilder.DropColumn( - name: "LocationCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "RawArea", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "ReturnQty", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Type", - table: "Store_ProductReceiptRequest"); - - migrationBuilder.DropColumn( - name: "RawArea", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ReturnQty", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ProductReceiptRequestNumber", - table: "Store_ProductReceiptNote"); - - migrationBuilder.DropColumn( - name: "Type", - table: "Store_ProductReceiptNote"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "Type", - table: "Store_MaterialRequest"); - - migrationBuilder.DropColumn( - name: "UseOnTheWayLocation", - table: "Store_MaterialRequest"); - - migrationBuilder.DropColumn( - name: "OnTheWayLocationCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ConfirmTime", - table: "Store_IssueNote"); - - migrationBuilder.DropColumn( - name: "Confirmed", - table: "Store_IssueNote"); - - migrationBuilder.DropColumn( - name: "RequestNumber", - table: "Store_IssueNote"); - - migrationBuilder.DropColumn( - name: "RequestType", - table: "Store_IssueNote"); - - migrationBuilder.DropColumn( - name: "UseOnTheWayLocation", - table: "Store_IssueNote"); - - migrationBuilder.DropColumn( - name: "AreaCode", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropColumn( - name: "DeliverTime", - table: "Store_DeliverRequest"); - - migrationBuilder.DropColumn( - name: "ExtraProperties", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "DeliverPlanNumber", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "DeliverRequestNumber", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "DeliverRequestType", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "DeliverTime", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "ToLocationCode", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "JsonInventoryStatus", - table: "Store_CountPlan"); - - migrationBuilder.DropColumn( - name: "JsonItemCodes", - table: "Store_CountPlan"); - - migrationBuilder.DropColumn( - name: "JsonLocationCodes", - table: "Store_CountPlan"); - - migrationBuilder.DropColumn( - name: "RequestType", - table: "Store_CountPlan"); - - migrationBuilder.DropColumn( - name: "CountAdjustRequestNumber", - table: "Store_CountAdjustNote"); - - migrationBuilder.DropColumn( - name: "IsAdjusted", - table: "Store_CountAdjustNote"); - - migrationBuilder.DropColumn( - name: "JobNumber", - table: "Store_CountAdjustNote"); - - migrationBuilder.DropColumn( - name: "Type", - table: "Store_CountAdjustNote"); - - migrationBuilder.DropColumn( - name: "RecommendErpCode", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.RenameColumn( - name: "UseOnTheWayLocation", - table: "Store_TransferRequest", - newName: "NeedInTransitLocation"); - - migrationBuilder.RenameColumn( - name: "OnTheWayLocationCode", - table: "Store_TransferNoteDetail", - newName: "InTransitLocation"); - - migrationBuilder.RenameColumn( - name: "UseOnTheWayLocation", - table: "Store_TransferNote", - newName: "NeedInTransitLocation"); - - migrationBuilder.RenameColumn( - name: "Confirmed", - table: "Store_TransferNote", - newName: "Adjusted"); - - migrationBuilder.RenameColumn( - name: "RecommendErpCode", - table: "Store_SupplierAsnDetail", - newName: "LocationErpCode"); - - migrationBuilder.RenameColumn( - name: "Type", - table: "Store_PutawayRequest", - newName: "PutawayType"); - - migrationBuilder.RenameColumn( - name: "PutawayMode", - table: "Store_PutawayRequest", - newName: "PutawayJobType"); - - migrationBuilder.RenameColumn( - name: "RequestNumber", - table: "Store_ProductRecycleNote", - newName: "PRRequestNumber"); - - migrationBuilder.RenameColumn( - name: "ToLocation_Group", - table: "Store_MaterialRequestDetail", - newName: "Location_Group"); - - migrationBuilder.RenameColumn( - name: "ToLocation_ErpCode", - table: "Store_MaterialRequestDetail", - newName: "Location_ErpCode"); - - migrationBuilder.RenameColumn( - name: "ToLocation_Area", - table: "Store_MaterialRequestDetail", - newName: "Location_Area"); - - migrationBuilder.RenameColumn( - name: "DeliverRequestType", - table: "Store_DeliverRequest", - newName: "DeliverType"); - - migrationBuilder.RenameColumn( - name: "CustomerCode", - table: "Store_DeliverNote", - newName: "Customer"); - - migrationBuilder.RenameColumn( - name: "TransInOut", - table: "Store_CountAdjustNoteDetail", - newName: "Type"); - - migrationBuilder.AlterColumn( - name: "RawQty_Uom", - table: "Store_WorkOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_WorkOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_WorkOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_WorkOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_WorkOrder", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_WorkOrder", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_WorkOrder", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_WorkOrder", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_WarehouseTransferNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_UnplannedReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_UnplannedReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_UnplannedIssueRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_UnplannedIssueNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromPackingCode", - table: "Store_TransferRequestDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "InTransitLocation", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_TransferRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "TransferType", - table: "Store_TransferRequest", - type: "int", - nullable: false, - defaultValue: 0); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_TransferNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "TransferType", - table: "Store_TransferNote", - type: "int", - nullable: false, - defaultValue: 0); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Phone", - table: "Store_SupplierAsn", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Name", - table: "Store_SupplierAsn", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Email", - table: "Store_SupplierAsn", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_SupplierAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLot", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ScrapNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_SaleOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_SaleOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_SaleOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_SaleOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_SaleOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "CustomerPack_PackUom", - table: "Store_SaleOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Phone", - table: "Store_SaleOrder", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Name", - table: "Store_SaleOrder", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Email", - table: "Store_SaleOrder", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_SaleOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_RecycledMaterialReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ReceiptAbnormalNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InventoryQty_Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_PutawayRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToPackingCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_PutawayNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_PurchaseReturnRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_PurchaseReturnNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_PurchaseReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Phone", - table: "Store_PurchaseOrder", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Name", - table: "Store_PurchaseOrder", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Email", - table: "Store_PurchaseOrder", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_PurchaseOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "RawLocation_Group", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RawLocation_ErpCode", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RawLocation_Area", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ProductRecycleRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "BomVersion", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RawLocationCode", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RawLocation_Area", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RawLocation_ErpCode", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RawLocation_Group", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ProductRecycleNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Workshop", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Team", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Shift", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProdLine", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RawLocation", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProdLine", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "WorkShop", - table: "Store_ProductReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ProductReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ProductL7PartsNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ProductionReturnRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToPackingCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ProductionReturnNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "PlanQty_Uom", - table: "Store_ProductionPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ProductionPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ProductionPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ProductionPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductionPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ProductionPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PreparationPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PreparationPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PreparationPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PreparationPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PreparationPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_PreparationPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_OfflineSettlementNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_MaterialRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_JisProductReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_JisDeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToQty_Uom", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Name", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Desc2", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Desc1", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToBatch_SupplierBatch", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromQty_Uom", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromBatch_SupplierBatch", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ItemTransformRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToQty_Uom", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Name", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Desc2", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItem_Desc1", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToBatch_SupplierBatch", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromQty_Uom", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromBatch_SupplierBatch", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ItemTransformNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_IssueNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_IsolationNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_InventoryTransferNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_InspectRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Phone", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Name", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Email", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Phone", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Name", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InspectUser_Email", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_InspectNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_InspectAbnormalNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_DeliverRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_DeliverRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_DeliverRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_DeliverRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_DeliverRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ExpiredTime", - table: "Store_DeliverRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "ToLocationCode", - table: "Store_DeliverRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "DeliverPlanNumber", - table: "Store_DeliverRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "CustomerAddressCode", - table: "Store_DeliverRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_DeliverRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_DeliverPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_DeliverPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_DeliverPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_DeliverPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_DeliverPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_DeliverPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToPackingCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLot", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromPackingCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLot", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "DeliverTime", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "ExpiredTime", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AlterColumn( - name: "CustomerAddressCode", - table: "Store_DeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_DeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocation_Group", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_ErpCode", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocation_Area", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Group", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_ErpCode", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocation_Area", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_CustomerReturnNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_CustomerAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_CustomerAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_CustomerAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_CustomerAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_CustomerAsnDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Phone", - table: "Store_CustomerAsn", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Name", - table: "Store_CustomerAsn", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Contacts_Email", - table: "Store_CustomerAsn", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_CustomerAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RepeatCount_Operator", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RepeatCount_Description", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InventoryQty_Uom", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FirstCount_Operator", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FirstCount_Description", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "AuditCount_Operator", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "AuditCount_Description", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_CountPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RepeatCount_Operator", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "RepeatCount_Description", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InventoryQty_Uom", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FirstCount_Operator", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FirstCount_Description", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "AuditCount_Operator", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "AuditCount_Description", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_CountNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "InventoryQty_Uom", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "JobNumber", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_CountAdjustNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_ContainerBindNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_BackFlushNote", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Group", - table: "Store_BackFlushNote", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_ErpCode", - table: "Store_BackFlushNote", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Location_Area", - table: "Store_BackFlushNote", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_BackFlushNote", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_BackFlushNote", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_BackFlushNote", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_BackFlushNote", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Uom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Name", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc2", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Item_Desc1", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(1024)", - oldMaxLength: 1024, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Company", - table: "Store_PurchaseReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.CreateIndex( - name: "IX_Store_WorkOrder_Number_Company", - table: "Store_WorkOrder", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_WarehouseTransferNote_Number_Company", - table: "Store_WarehouseTransferNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptRequestDetail_Number_ItemCode", - table: "Store_UnplannedReceiptRequestDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptRequest_Company_Number", - table: "Store_UnplannedReceiptRequest", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptNoteDetail_Number_PackingCode", - table: "Store_UnplannedReceiptNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedReceiptNote_Number_Company", - table: "Store_UnplannedReceiptNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueRequestDetail_Number_ItemCode", - table: "Store_UnplannedIssueRequestDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueRequest_Company_Number", - table: "Store_UnplannedIssueRequest", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueNoteDetail_Number_PackingCode", - table: "Store_UnplannedIssueNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_UnplannedIssueNote_Number_Company", - table: "Store_UnplannedIssueNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferRequestDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode_FromStatus_ToStatus", - table: "Store_TransferRequestDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferRequest_Number_Company", - table: "Store_TransferRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_TransferNote_Number_Company", - table: "Store_TransferNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_SupplierAsn_Number_Company", - table: "Store_SupplierAsn", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ScrapNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_ScrapNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ScrapNote_Number_Company", - table: "Store_ScrapNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_SaleOrder_Number_Company", - table: "Store_SaleOrder", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_RecycledMaterialReceiptNote_Number_Company", - table: "Store_RecycledMaterialReceiptNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ReceiptAbnormalNote_AsnNumber_Number_Company_SupplierCode_ReceiptNumber", - table: "Store_ReceiptAbnormalNote", - columns: new[] { "AsnNumber", "Number", "Company", "SupplierCode", "ReceiptNumber" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayRequest_Number_Company", - table: "Store_PutawayRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_PutawayNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_PutawayNote_Number_Company", - table: "Store_PutawayNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReturnRequest_Number_Company", - table: "Store_PurchaseReturnRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReturnNote_Number_Company", - table: "Store_PurchaseReturnNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptNote_Number_Company", - table: "Store_PurchaseReceiptNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseOrder_Number_Company", - table: "Store_PurchaseOrder", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleRequest_Number_Company", - table: "Store_ProductRecycleRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductRecycleNote_Number_Company", - table: "Store_ProductRecycleNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptRequestDetail_Number_ItemCode", - table: "Store_ProductReceiptRequestDetail", - columns: new[] { "Number", "ItemCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptRequest_Number_Company", - table: "Store_ProductReceiptRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptNoteDetail_Number_PackingCode", - table: "Store_ProductReceiptNoteDetail", - columns: new[] { "Number", "PackingCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptNote_Company_Number", - table: "Store_ProductReceiptNote", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductL7PartsNote_Company_Number", - table: "Store_ProductL7PartsNote", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnRequest_Company_Number", - table: "Store_ProductionReturnRequest", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_ProductionReturnNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnNote_Number_Company", - table: "Store_ProductionReturnNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionPlan_Number_Company", - table: "Store_ProductionPlan", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PreparationPlan_Number_Company", - table: "Store_PreparationPlan", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_OfflineSettlementNote_Number_Company", - table: "Store_OfflineSettlementNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_MaterialRequest_Company_Number", - table: "Store_MaterialRequest", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_JisProductReceiptNote_Company_Number", - table: "Store_JisProductReceiptNote", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_JisDeliverNote_Company_Number", - table: "Store_JisDeliverNote", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ItemTransformRequest_Number_Company", - table: "Store_ItemTransformRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ItemTransformNote_Number_Company", - table: "Store_ItemTransformNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_IssueNote_Number_Company", - table: "Store_IssueNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_IsolationNote_Number_Company", - table: "Store_IsolationNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InventoryTransferNote_Number_Company", - table: "Store_InventoryTransferNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectRequest_Number_Company", - table: "Store_InspectRequest", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectNote_Number_Company", - table: "Store_InspectNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_InspectAbnormalNote_Number_Company", - table: "Store_InspectAbnormalNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverRequestDetail_Number_ItemCode_ExpiredTime_ToLocationCode", - table: "Store_DeliverRequestDetail", - columns: new[] { "Number", "ItemCode", "ExpiredTime", "ToLocationCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverRequest_Company_Number", - table: "Store_DeliverRequest", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverPlan_Number_Company", - table: "Store_DeliverPlan", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", - table: "Store_DeliverNoteDetail", - columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, - unique: true, - filter: "[FromPackingCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_DeliverNote_Company_Number", - table: "Store_DeliverNote", - columns: new[] { "Company", "Number" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerReturnNote_Number_Company", - table: "Store_CustomerReturnNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CustomerAsn_Number_Company", - table: "Store_CustomerAsn", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountPlan_Number_Company", - table: "Store_CountPlan", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountNote_Number_Company", - table: "Store_CountNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountAdjustNoteDetail_Number_CountLabel", - table: "Store_CountAdjustNoteDetail", - columns: new[] { "Number", "CountLabel" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_CountAdjustNote_Number_Company", - table: "Store_CountAdjustNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ContainerBindNote_Number_Company", - table: "Store_ContainerBindNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_BackFlushNote_Number_Company", - table: "Store_BackFlushNote", - columns: new[] { "Number", "Company" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_PurchaseReceiptRequest_Number_Company", - table: "Store_PurchaseReceiptRequest", - columns: new[] { "Number", "Company" }, - unique: true); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230105062711_RemoveWarehouseCodeInDetail.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230105062711_RemoveWarehouseCodeInDetail.Designer.cs deleted file mode 100644 index 86a7aa98c..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230105062711_RemoveWarehouseCodeInDetail.Designer.cs +++ /dev/null @@ -1,19525 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230105062711_RemoveWarehouseCodeInDetail")] - partial class RemoveWarehouseCodeInDetail - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasColumnType("nvarchar(450)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RequestType") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveUom") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RawLocation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique() - .HasFilter("[LocationCode] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("HandledContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledLot") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("RecommendContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendLot") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreateType") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "AuditCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "FirstCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "RepeatCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.Navigation("AuditCount"); - - b.Navigation("Batch"); - - b.Navigation("FirstCount"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RepeatCount"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "AuditCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "FirstCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "RepeatCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.Navigation("AuditCount"); - - b.Navigation("Batch"); - - b.Navigation("FirstCount"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RepeatCount"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CustomerAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CustomerAsnId"); - - b1.ToTable("Store_CustomerAsn"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("CustomerAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnId"); - - b1.ToTable("Store_CustomerAsn"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnId"); - }); - - b.Navigation("Contacts"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteId"); - - b1.ToTable("Store_DeliverNote"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteId"); - }); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("InspectAbnormalNoteDetailId", "PhotoID"); - - b1.ToTable("Store_InspectAbnormalNoteDetailPhoto", (string)null); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Photos"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "InspectUser", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("InspectNoteDetailId", "PhotoID"); - - b1.ToTable("Store_InspectNoteDetailPhoto", (string)null); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InspectUser"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Photos"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "InspectUser", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InspectUser"); - - b.Navigation("Item"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ReceiveQty", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("ReceiveQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "FromQty", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ToQty", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("FromQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - - b.Navigation("ToQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "FromQty", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "ToQty", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("FromQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - - b.Navigation("ToQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "PlanQty", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("PlanQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductL7PartsNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductL7PartsNoteDetailId"); - - b1.ToTable("Store_ProductL7PartsNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductL7PartsNoteDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ProductItem", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ProductItem"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "RawLocation", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("RawLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("PurchaseOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderId"); - - b1.ToTable("Store_PurchaseOrder"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "HandledBatch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "HandledLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "HandledQty", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "InventoryQty", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "RecommendBatch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "RecommendLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "RecommendQty", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("HandledBatch"); - - b.Navigation("HandledLocation"); - - b.Navigation("HandledQty"); - - b.Navigation("InventoryQty"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("RecommendBatch"); - - b.Navigation("RecommendLocation"); - - b.Navigation("RecommendQty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("ReceiptAbnormalNoteDetailId", "PhotoID"); - - b1.ToTable("Store_ReceiptAbnormalNotePhoto", (string)null); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Photos"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("SaleOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderId"); - - b1.ToTable("Store_SaleOrder"); - - b1.WithOwner() - .HasForeignKey("SaleOrderId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "CustomerPack", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.Navigation("CustomerPack"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("SupplierAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnId"); - - b1.ToTable("Store_SupplierAsn"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "SupplierPack", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("SupplierPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.PackInfo", "StdPack", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PackQty") - .HasColumnType("decimal(18,6)"); - - b1.Property("PackUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Qty"); - - b.Navigation("StdPack"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "Qty", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.Navigation("Item"); - - b.Navigation("Qty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.UomQty", "RawQty", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("RawQty"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230105062711_RemoveWarehouseCodeInDetail.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230105062711_RemoveWarehouseCodeInDetail.cs deleted file mode 100644 index d9e2fd363..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230105062711_RemoveWarehouseCodeInDetail.cs +++ /dev/null @@ -1,406 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class RemoveWarehouseCodeInDetail : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductL7PartsNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InspectAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ContainerBindNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptRequestDetail"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - nullable: false, - defaultValue: ""); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230106060036_SplitUomQtyAndPackInfo.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230106060036_SplitUomQtyAndPackInfo.Designer.cs deleted file mode 100644 index 3530da5d5..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230106060036_SplitUomQtyAndPackInfo.Designer.cs +++ /dev/null @@ -1,17310 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230106060036_SplitUomQtyAndPackInfo")] - partial class SplitUomQtyAndPackInfo - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasColumnType("nvarchar(450)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RequestType") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique() - .HasFilter("[LocationCode] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreateType") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "AuditCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "FirstCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "RepeatCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.Navigation("AuditCount"); - - b.Navigation("Batch"); - - b.Navigation("FirstCount"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RepeatCount"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "AuditCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "FirstCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "RepeatCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.Navigation("AuditCount"); - - b.Navigation("Batch"); - - b.Navigation("FirstCount"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RepeatCount"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.TimeRange", "TimeRange", b1 => - { - b1.Property("CustomerAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("BeginTime") - .HasColumnType("datetime2"); - - b1.Property("EndTime") - .HasColumnType("datetime2"); - - b1.HasKey("CustomerAsnId"); - - b1.ToTable("Store_CustomerAsn"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("CustomerAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnId"); - - b1.ToTable("Store_CustomerAsn"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnId"); - }); - - b.Navigation("Contacts"); - - b.Navigation("TimeRange"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteId"); - - b1.ToTable("Store_DeliverNote"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteId"); - }); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("InspectAbnormalNoteDetailId", "PhotoID"); - - b1.ToTable("Store_InspectAbnormalNoteDetailPhoto", (string)null); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Photos"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "InspectUser", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("InspectNoteDetailId", "PhotoID"); - - b1.ToTable("Store_InspectNoteDetailPhoto", (string)null); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InspectUser"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Photos"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "InspectUser", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InspectUser"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductL7PartsNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductL7PartsNoteDetailId"); - - b1.ToTable("Store_ProductL7PartsNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductL7PartsNoteDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ProductItem", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ProductItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "RawLocation", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RawLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("PurchaseOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderId"); - - b1.ToTable("Store_PurchaseOrder"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsMany("Win_in.Sfs.Shared.Domain.Photo", "Photos", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("PhotoID") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b1.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b1.HasKey("ReceiptAbnormalNoteDetailId", "PhotoID"); - - b1.ToTable("Store_ReceiptAbnormalNotePhoto", (string)null); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("Photos"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("SaleOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderId"); - - b1.ToTable("Store_SaleOrder"); - - b1.WithOwner() - .HasForeignKey("SaleOrderId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("SupplierAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnId"); - - b1.ToTable("Store_SupplierAsn"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230106060036_SplitUomQtyAndPackInfo.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230106060036_SplitUomQtyAndPackInfo.cs deleted file mode 100644 index 46417b612..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230106060036_SplitUomQtyAndPackInfo.cs +++ /dev/null @@ -1,4618 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class SplitUomQtyAndPackInfo : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "RawQty_Qty", - table: "Store_WorkOrderDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "CustomerPack_PackQty", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "CustomerPack_PackUom", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledBatch_ArriveDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledBatch_ExpireDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledBatch_ProduceDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledBatch_SupplierBatch", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledLocationCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledLocation_Area", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledLocation_ErpCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledLocation_Group", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty_Qty", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty_Uom", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty_Qty", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty_Uom", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "Qty_Qty", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "Qty_Uom", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendBatch_ArriveDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendBatch_ExpireDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendBatch_ProduceDate", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendBatch_SupplierBatch", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLocationCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLocation_Area", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLocation_ErpCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLocation_Group", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "PlanQty_Qty", - table: "Store_ProductionPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_PreparationPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_PreparationPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromQty_Qty", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromQty_Uom", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToQty_Qty", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromQty_Qty", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromQty_Uom", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToQty_Qty", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "ReceiveQty_Qty", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "ReceiveQty_Qty", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "ReceiveUom", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "ReceiveQty_Qty", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "ReceiveQty_Qty", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_InspectAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_InspectAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_DeliverPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_DeliverPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_CustomerAsnDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_CustomerAsnDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty_Qty", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty_Qty", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty_Qty", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty_Uom", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty_Qty", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_ContainerBindNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_ContainerBindNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackQty", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackQty", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.RenameColumn( - name: "RawQty_Uom", - table: "Store_WorkOrderDetail", - newName: "RawUom"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_WorkOrder", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_WorkOrder", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_WarehouseTransferNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_WarehouseTransferNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_UnplannedReceiptRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_UnplannedReceiptRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_UnplannedReceiptNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_UnplannedReceiptNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_UnplannedIssueRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_UnplannedIssueRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_UnplannedIssueNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_UnplannedIssueNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_TransferRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_TransferRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_TransferNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_TransferNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_SupplierAsnDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_SupplierAsnDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ScrapRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ScrapRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ScrapNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ScrapNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_SaleOrderDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_SaleOrderDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "RecommendQty_Uom", - table: "Store_PutawayRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "RecommendQty_Qty", - table: "Store_PutawayRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_PutawayNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_PutawayNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_PurchaseReturnRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_PurchaseReturnRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_PurchaseReturnNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_PurchaseReturnNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_PurchaseReceiptNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_PurchaseReceiptNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_PurchaseOrderDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_PurchaseOrderDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ProductRecycleRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ProductRecycleRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ProductRecycleNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ProductRecycleNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ProductRecycleMaterialDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ProductRecycleMaterialDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ProductReceiptRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ProductReceiptRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ProductReceiptNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ProductReceiptNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ProductionReturnRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ProductionReturnRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ProductionReturnNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ProductionReturnNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "PlanQty_Uom", - table: "Store_ProductionPlanDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_PreparationPlanDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_PreparationPlanDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_OfflineSettlementNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_OfflineSettlementNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_NoOkConvertOkNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_NoOkConvertOkNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_MaterialRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_MaterialRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_JisProductReceiptNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_JisProductReceiptNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_JisDeliverNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_JisDeliverNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "ToQty_Uom", - table: "Store_ItemTransformRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "ToQty_Uom", - table: "Store_ItemTransformNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_IssueNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_IssueNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_IsolationNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_IsolationNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_InventoryTransferNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_InventoryTransferNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_InventoryInitialNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_InventoryInitialNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectRequestSummaryDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectNoteSummaryDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "ReceiveQty_Uom", - table: "Store_InspectNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_InspectAbnormalNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_InspectAbnormalNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_DeliverRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_DeliverRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_DeliverPlanDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_DeliverPlanDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_DeliverNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_DeliverNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_CustomerReturnNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_CustomerReturnNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_CustomerAsnDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_CustomerAsnDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "InventoryQty_Uom", - table: "Store_CountPlanDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "InventoryQty_Uom", - table: "Store_CountNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_CountAdjustRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_CountAdjustRequestDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "InventoryQty_Uom", - table: "Store_CountAdjustNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_ContainerBindNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_ContainerBindNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_BackFlushNoteDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_BackFlushNoteDetail", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_BackFlushNote", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_BackFlushNote", - newName: "Qty"); - - migrationBuilder.RenameColumn( - name: "Qty_Uom", - table: "Store_PurchaseReceiptRequestDetail", - newName: "Uom"); - - migrationBuilder.RenameColumn( - name: "Qty_Qty", - table: "Store_PurchaseReceiptRequestDetail", - newName: "Qty"); - - migrationBuilder.AddColumn( - name: "RawQty", - table: "Store_WorkOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_WorkOrder", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_WarehouseTransferNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_WarehouseTransferNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_UnplannedReceiptRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_UnplannedReceiptRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_UnplannedReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_UnplannedReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_UnplannedIssueRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_UnplannedIssueRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_UnplannedIssueNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_UnplannedIssueNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_TransferRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_TransferRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_TransferNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_TransferNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_SupplierAsnDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_SupplierAsnDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "SupplierPackQty", - table: "Store_SupplierAsnDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "SupplierPackUom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ScrapRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_ScrapRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ScrapNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_ScrapNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_SaleOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "CustomerPackQty", - table: "Store_SaleOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "CustomerPackUom", - table: "Store_SaleOrderDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_SaleOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ReceiptAbnormalNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_ReceiptAbnormalNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "InventoryQty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_PutawayNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_PutawayNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_PurchaseReturnRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_PurchaseReturnRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_PurchaseReturnNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_PurchaseReturnNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_PurchaseReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_PurchaseReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "SupplierPackQty", - table: "Store_PurchaseReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "SupplierPackUom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_PurchaseOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_PurchaseOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "SupplierPackQty", - table: "Store_PurchaseOrderDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "SupplierPackUom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ProductRecycleRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ProductRecycleNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_ProductRecycleNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ProductRecycleMaterialDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_ProductRecycleMaterialDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ProductReceiptRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_ProductReceiptRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_ProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ProductionReturnRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_ProductionReturnRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ProductionReturnNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_ProductionReturnNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "PlanQty", - table: "Store_ProductionPlanDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_PreparationPlanDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_PreparationPlanDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_OfflineSettlementNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_OfflineSettlementNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_NoOkConvertOkNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_NoOkConvertOkNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_MaterialRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_MaterialRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_JisProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_JisProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_JisDeliverNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_JisDeliverNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "FromQty", - table: "Store_ItemTransformRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "ToQty", - table: "Store_ItemTransformRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "FromQty", - table: "Store_ItemTransformNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "ToQty", - table: "Store_ItemTransformNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_IssueNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_IssueNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_IsolationNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_IsolationNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_InventoryTransferNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_InventoryTransferNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_InventoryInitialNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_InventoryInitialNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "ReceiveQty", - table: "Store_InspectRequestSummaryDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_InspectRequestSummaryDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "ReceiveQty", - table: "Store_InspectRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_InspectRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "ReceiveQty", - table: "Store_InspectNoteSummaryDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_InspectNoteSummaryDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "ReceiveQty", - table: "Store_InspectNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_InspectNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_InspectAbnormalNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_InspectAbnormalNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_DeliverRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_DeliverRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_DeliverPlanDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_DeliverPlanDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_DeliverNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_DeliverNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_CustomerReturnNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_CustomerReturnNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_CustomerAsnDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_CustomerAsnDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "InventoryQty", - table: "Store_CountPlanDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_CountPlanDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "InventoryQty", - table: "Store_CountNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_CountNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_CountAdjustRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "InventoryQty", - table: "Store_CountAdjustRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_CountAdjustRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "InventoryQty", - table: "Store_CountAdjustNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_CountAdjustNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_ContainerBindNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_ContainerBindNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_BackFlushNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_BackFlushNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_BackFlushNote", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Qty", - table: "Store_PurchaseReceiptRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "StdPackQty", - table: "Store_PurchaseReceiptRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "SupplierPackQty", - table: "Store_PurchaseReceiptRequestDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "SupplierPackUom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - nullable: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "RawQty", - table: "Store_WorkOrderDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPackQty", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPackUom", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "CustomerPackQty", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "CustomerPackUom", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPackQty", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPackUom", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPackQty", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPackUom", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "PlanQty", - table: "Store_ProductionPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_PreparationPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromQty", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToQty", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromQty", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToQty", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "ReceiveQty", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "ReceiveQty", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "ReceiveQty", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "ReceiveQty", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_InspectAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_DeliverPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_CustomerAsnDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "InventoryQty", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_ContainerBindNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "StdPackQty", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPackQty", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "SupplierPackUom", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.RenameColumn( - name: "RawUom", - table: "Store_WorkOrderDetail", - newName: "RawQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_WorkOrder", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_WorkOrder", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_WarehouseTransferNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_WarehouseTransferNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_UnplannedReceiptRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_UnplannedReceiptRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_UnplannedReceiptNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_UnplannedReceiptNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_UnplannedIssueRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_UnplannedIssueRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_UnplannedIssueNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_UnplannedIssueNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_TransferRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_TransferRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_TransferNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_TransferNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_SupplierAsnDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_SupplierAsnDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ScrapRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ScrapRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ScrapNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ScrapNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_SaleOrderDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_SaleOrderDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_PutawayRequestDetail", - newName: "RecommendQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_PutawayRequestDetail", - newName: "RecommendQty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_PutawayNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_PutawayNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_PurchaseReturnRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_PurchaseReturnRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_PurchaseReturnNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_PurchaseReturnNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_PurchaseReceiptNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_PurchaseReceiptNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_PurchaseOrderDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_PurchaseOrderDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ProductRecycleRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ProductRecycleRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ProductRecycleNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ProductRecycleNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ProductRecycleMaterialDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ProductRecycleMaterialDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ProductReceiptRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ProductReceiptRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ProductReceiptNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ProductReceiptNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ProductionReturnRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ProductionReturnRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ProductionReturnNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ProductionReturnNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ProductionPlanDetail", - newName: "PlanQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_PreparationPlanDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_PreparationPlanDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_OfflineSettlementNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_OfflineSettlementNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_NoOkConvertOkNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_NoOkConvertOkNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_MaterialRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_MaterialRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_JisProductReceiptNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_JisProductReceiptNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_JisDeliverNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_JisDeliverNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ItemTransformRequestDetail", - newName: "ToQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ItemTransformNoteDetail", - newName: "ToQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_IssueNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_IssueNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_IsolationNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_IsolationNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_InventoryTransferNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_InventoryTransferNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_InventoryInitialNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_InventoryInitialNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_InspectRequestSummaryDetail", - newName: "ReceiveQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_InspectRequestDetail", - newName: "ReceiveQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_InspectNoteSummaryDetail", - newName: "ReceiveQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_InspectNoteDetail", - newName: "ReceiveQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_InspectAbnormalNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_InspectAbnormalNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_DeliverRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_DeliverRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_DeliverPlanDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_DeliverPlanDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_DeliverNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_DeliverNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_CustomerReturnNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_CustomerReturnNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_CustomerAsnDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_CustomerAsnDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_CountPlanDetail", - newName: "InventoryQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_CountNoteDetail", - newName: "InventoryQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_CountAdjustRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_CountAdjustRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_CountAdjustNoteDetail", - newName: "InventoryQty_Uom"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_ContainerBindNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_ContainerBindNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_BackFlushNoteDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_BackFlushNoteDetail", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_BackFlushNote", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_BackFlushNote", - newName: "Qty_Qty"); - - migrationBuilder.RenameColumn( - name: "Uom", - table: "Store_PurchaseReceiptRequestDetail", - newName: "Qty_Uom"); - - migrationBuilder.RenameColumn( - name: "Qty", - table: "Store_PurchaseReceiptRequestDetail", - newName: "Qty_Qty"); - - migrationBuilder.AddColumn( - name: "RawQty_Qty", - table: "Store_WorkOrderDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_WorkOrder", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_WarehouseTransferNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_WarehouseTransferNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_UnplannedReceiptRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_UnplannedReceiptRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_UnplannedReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_UnplannedReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_UnplannedIssueRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_UnplannedIssueRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_UnplannedIssueNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_UnplannedIssueNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_TransferRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_TransferRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_TransferNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_TransferNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_SupplierAsnDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_SupplierAsnDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_SupplierAsnDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ScrapRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_ScrapRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ScrapNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_ScrapNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_SaleOrderDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "CustomerPack_PackQty", - table: "Store_SaleOrderDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "CustomerPack_PackUom", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_SaleOrderDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ReceiptAbnormalNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_ReceiptAbnormalNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "RecommendQty_Qty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "HandledBatch_ArriveDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledBatch_ExpireDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledBatch_ProduceDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledBatch_SupplierBatch", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLocationCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLocation_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLocation_ErpCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLocation_Group", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledQty_Qty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledQty_Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "InventoryQty_Qty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "InventoryQty_Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Qty_Qty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Qty_Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendBatch_ArriveDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendBatch_ExpireDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendBatch_ProduceDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendBatch_SupplierBatch", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLocationCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLocation_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLocation_ErpCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLocation_Group", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_PutawayRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_PutawayNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_PutawayNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_PutawayNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_PurchaseReturnRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_PurchaseReturnRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_PurchaseReturnNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_PurchaseReturnNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_PurchaseReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_PurchaseReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_PurchaseReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_PurchaseOrderDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_PurchaseOrderDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_PurchaseOrderDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ProductRecycleRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ProductRecycleNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_ProductRecycleNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ProductRecycleMaterialDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_ProductRecycleMaterialDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ProductReceiptRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_ProductReceiptRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_ProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ProductionReturnRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_ProductionReturnRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ProductionReturnNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_ProductionReturnNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "PlanQty_Qty", - table: "Store_ProductionPlanDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_PreparationPlanDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_PreparationPlanDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_PreparationPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_OfflineSettlementNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_OfflineSettlementNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_NoOkConvertOkNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_NoOkConvertOkNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_MaterialRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_MaterialRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_JisProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_JisProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_JisDeliverNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_JisDeliverNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromQty_Qty", - table: "Store_ItemTransformRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromQty_Uom", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToQty_Qty", - table: "Store_ItemTransformRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromQty_Qty", - table: "Store_ItemTransformNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromQty_Uom", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToQty_Qty", - table: "Store_ItemTransformNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_IssueNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_IssueNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_IsolationNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_IsolationNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_InventoryTransferNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_InventoryTransferNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_InventoryInitialNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_InventoryInitialNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ReceiveQty_Qty", - table: "Store_InspectRequestSummaryDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_InspectRequestSummaryDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_InspectRequestSummaryDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ReceiveQty_Qty", - table: "Store_InspectRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "ReceiveUom", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_InspectRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_InspectRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ReceiveQty_Qty", - table: "Store_InspectNoteSummaryDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_InspectNoteSummaryDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_InspectNoteSummaryDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ReceiveQty_Qty", - table: "Store_InspectNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_InspectNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_InspectNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_InspectAbnormalNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_InspectAbnormalNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_DeliverRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_DeliverRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_DeliverRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_DeliverPlanDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_DeliverPlanDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_DeliverPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_DeliverNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_DeliverNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_CustomerReturnNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_CustomerReturnNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_CustomerAsnDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_CustomerAsnDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_CustomerAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "InventoryQty_Qty", - table: "Store_CountPlanDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_CountPlanDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "InventoryQty_Uom", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "InventoryQty_Qty", - table: "Store_CountNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_CountNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_CountAdjustRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "InventoryQty_Qty", - table: "Store_CountAdjustRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "InventoryQty_Uom", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_CountAdjustRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "InventoryQty_Qty", - table: "Store_CountAdjustNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_CountAdjustNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_ContainerBindNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_ContainerBindNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_BackFlushNoteDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_BackFlushNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_BackFlushNote", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AlterColumn( - name: "Qty_Qty", - table: "Store_PurchaseReceiptRequestDetail", - type: "decimal(18,6)", - nullable: true, - oldClrType: typeof(decimal), - oldType: "decimal(18,6)"); - - migrationBuilder.AddColumn( - name: "StdPack_PackQty", - table: "Store_PurchaseReceiptRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "StdPack_PackUom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackQty", - table: "Store_PurchaseReceiptRequestDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierPack_PackUom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109015238_FlatTimeRangeAndPhoto.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109015238_FlatTimeRangeAndPhoto.Designer.cs deleted file mode 100644 index 56c8d9f62..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109015238_FlatTimeRangeAndPhoto.Designer.cs +++ /dev/null @@ -1,17238 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230109015238_FlatTimeRangeAndPhoto")] - partial class FlatTimeRangeAndPhoto - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasColumnType("nvarchar(450)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RequestType") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique() - .HasFilter("[LocationCode] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreateType") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "AuditCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "FirstCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "RepeatCount", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.Navigation("AuditCount"); - - b.Navigation("Batch"); - - b.Navigation("FirstCount"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RepeatCount"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "AuditCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "FirstCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.CountResult", "RepeatCount", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Description") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Operator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b1.Property("Time") - .HasColumnType("datetime2"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.Navigation("AuditCount"); - - b.Navigation("Batch"); - - b.Navigation("FirstCount"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RepeatCount"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("CustomerAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnId"); - - b1.ToTable("Store_CustomerAsn"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteId"); - - b1.ToTable("Store_DeliverNote"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteId"); - }); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "InspectUser", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InspectUser"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "InspectUser", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("InspectUser"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductL7PartsNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductL7PartsNoteDetailId"); - - b1.ToTable("Store_ProductL7PartsNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductL7PartsNoteDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ProductItem", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ProductItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "RawLocation", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RawLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("PurchaseOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderId"); - - b1.ToTable("Store_PurchaseOrder"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("SaleOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderId"); - - b1.ToTable("Store_SaleOrder"); - - b1.WithOwner() - .HasForeignKey("SaleOrderId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Person", "Contacts", b1 => - { - b1.Property("SupplierAsnId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Email") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Phone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnId"); - - b1.ToTable("Store_SupplierAsn"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnId"); - }); - - b.Navigation("Contacts"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109015238_FlatTimeRangeAndPhoto.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109015238_FlatTimeRangeAndPhoto.cs deleted file mode 100644 index 0680fa8fd..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109015238_FlatTimeRangeAndPhoto.cs +++ /dev/null @@ -1,167 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class FlatTimeRangeAndPhoto : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropTable( - name: "Store_InspectAbnormalNoteDetailPhoto"); - - migrationBuilder.DropTable( - name: "Store_InspectNoteDetailPhoto"); - - migrationBuilder.DropTable( - name: "Store_ReceiptAbnormalNotePhoto"); - - migrationBuilder.RenameColumn( - name: "TimeRange_EndTime", - table: "Store_CustomerAsn", - newName: "EndTime"); - - migrationBuilder.RenameColumn( - name: "TimeRange_BeginTime", - table: "Store_CustomerAsn", - newName: "BeginTime"); - - migrationBuilder.AddColumn( - name: "Photos", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Photos", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Photos", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "EndTime", - table: "Store_CountPlan", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "BeginTime", - table: "Store_CountPlan", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "Photos", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "Photos", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "Photos", - table: "Store_InspectAbnormalNoteDetail"); - - migrationBuilder.RenameColumn( - name: "EndTime", - table: "Store_CustomerAsn", - newName: "TimeRange_EndTime"); - - migrationBuilder.RenameColumn( - name: "BeginTime", - table: "Store_CustomerAsn", - newName: "TimeRange_BeginTime"); - - migrationBuilder.AlterColumn( - name: "EndTime", - table: "Store_CountPlan", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "BeginTime", - table: "Store_CountPlan", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.CreateTable( - name: "Store_InspectAbnormalNoteDetailPhoto", - columns: table => new - { - InspectAbnormalNoteDetailId = table.Column(type: "uniqueidentifier", nullable: false), - PhotoID = table.Column(type: "uniqueidentifier", nullable: false), - MasterID = table.Column(type: "uniqueidentifier", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectAbnormalNoteDetailPhoto", x => new { x.InspectAbnormalNoteDetailId, x.PhotoID }); - table.ForeignKey( - name: "FK_Store_InspectAbnormalNoteDetailPhoto_Store_InspectAbnormalNoteDetail_InspectAbnormalNoteDetailId", - column: x => x.InspectAbnormalNoteDetailId, - principalTable: "Store_InspectAbnormalNoteDetail", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_InspectNoteDetailPhoto", - columns: table => new - { - InspectNoteDetailId = table.Column(type: "uniqueidentifier", nullable: false), - PhotoID = table.Column(type: "uniqueidentifier", nullable: false), - MasterID = table.Column(type: "uniqueidentifier", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_InspectNoteDetailPhoto", x => new { x.InspectNoteDetailId, x.PhotoID }); - table.ForeignKey( - name: "FK_Store_InspectNoteDetailPhoto_Store_InspectNoteDetail_InspectNoteDetailId", - column: x => x.InspectNoteDetailId, - principalTable: "Store_InspectNoteDetail", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Store_ReceiptAbnormalNotePhoto", - columns: table => new - { - ReceiptAbnormalNoteDetailId = table.Column(type: "uniqueidentifier", nullable: false), - PhotoID = table.Column(type: "uniqueidentifier", nullable: false), - MasterID = table.Column(type: "uniqueidentifier", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Store_ReceiptAbnormalNotePhoto", x => new { x.ReceiptAbnormalNoteDetailId, x.PhotoID }); - table.ForeignKey( - name: "FK_Store_ReceiptAbnormalNotePhoto_Store_ReceiptAbnormalNoteDetail_ReceiptAbnormalNoteDetailId", - column: x => x.ReceiptAbnormalNoteDetailId, - principalTable: "Store_ReceiptAbnormalNoteDetail", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109070330_FlatPersonCountResult.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109070330_FlatPersonCountResult.Designer.cs deleted file mode 100644 index 1f51cc617..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109070330_FlatPersonCountResult.Designer.cs +++ /dev/null @@ -1,17032 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230109070330_FlatPersonCountResult")] - partial class FlatPersonCountResult - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasColumnType("nvarchar(450)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RequestType") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocation") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique() - .HasFilter("[LocationCode] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreateType") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteId"); - - b1.ToTable("Store_DeliverNote"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteId"); - }); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductL7PartsNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductL7PartsNoteDetailId"); - - b1.ToTable("Store_ProductL7PartsNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductL7PartsNoteDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ProductItem", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ProductItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "RawLocation", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("RawLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("Location"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "Location", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("Location"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "FromLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Location", "ToLocation", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Area") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("ErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.Property("Group") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("FromLocation"); - - b.Navigation("Item"); - - b.Navigation("ToLocation"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109070330_FlatPersonCountResult.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109070330_FlatPersonCountResult.cs deleted file mode 100644 index a010d82a6..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230109070330_FlatPersonCountResult.cs +++ /dev/null @@ -1,588 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class FlatPersonCountResult : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "InspectUser_Email", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "InspectUser_Name", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "InspectUser_Email", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "InspectUser_Name", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "AuditCount_Description", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "AuditCount_Qty", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "FirstCount_Description", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "FirstCount_Qty", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "RepeatCount_Description", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "RepeatCount_Qty", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "AuditCount_Description", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "AuditCount_Qty", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "FirstCount_Description", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "FirstCount_Qty", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "RepeatCount_Description", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "RepeatCount_Qty", - table: "Store_CountNoteDetail"); - - migrationBuilder.RenameColumn( - name: "Contacts_Phone", - table: "Store_SupplierAsn", - newName: "ContactPhone"); - - migrationBuilder.RenameColumn( - name: "Contacts_Name", - table: "Store_SupplierAsn", - newName: "ContactName"); - - migrationBuilder.RenameColumn( - name: "Contacts_Email", - table: "Store_SupplierAsn", - newName: "ContactEmail"); - - migrationBuilder.RenameColumn( - name: "Contacts_Phone", - table: "Store_SaleOrder", - newName: "ContactPhone"); - - migrationBuilder.RenameColumn( - name: "Contacts_Name", - table: "Store_SaleOrder", - newName: "ContactName"); - - migrationBuilder.RenameColumn( - name: "Contacts_Email", - table: "Store_SaleOrder", - newName: "ContactEmail"); - - migrationBuilder.RenameColumn( - name: "Contacts_Phone", - table: "Store_PurchaseOrder", - newName: "ContactPhone"); - - migrationBuilder.RenameColumn( - name: "Contacts_Name", - table: "Store_PurchaseOrder", - newName: "ContactName"); - - migrationBuilder.RenameColumn( - name: "Contacts_Email", - table: "Store_PurchaseOrder", - newName: "ContactEmail"); - - migrationBuilder.RenameColumn( - name: "InspectUser_Phone", - table: "Store_InspectNoteSummaryDetail", - newName: "InspectUser"); - - migrationBuilder.RenameColumn( - name: "InspectUser_Phone", - table: "Store_InspectNoteDetail", - newName: "InspectUser"); - - migrationBuilder.RenameColumn( - name: "Contacts_Phone", - table: "Store_CustomerAsn", - newName: "ContactPhone"); - - migrationBuilder.RenameColumn( - name: "Contacts_Name", - table: "Store_CustomerAsn", - newName: "ContactName"); - - migrationBuilder.RenameColumn( - name: "Contacts_Email", - table: "Store_CustomerAsn", - newName: "ContactEmail"); - - migrationBuilder.RenameColumn( - name: "RepeatCount_Time", - table: "Store_CountPlanDetail", - newName: "RepeatCountTime"); - - migrationBuilder.RenameColumn( - name: "RepeatCount_Operator", - table: "Store_CountPlanDetail", - newName: "RepeatCountOperator"); - - migrationBuilder.RenameColumn( - name: "FirstCount_Time", - table: "Store_CountPlanDetail", - newName: "FirstCountTime"); - - migrationBuilder.RenameColumn( - name: "FirstCount_Operator", - table: "Store_CountPlanDetail", - newName: "RepeatCountDescription"); - - migrationBuilder.RenameColumn( - name: "AuditCount_Time", - table: "Store_CountPlanDetail", - newName: "AuditCountTime"); - - migrationBuilder.RenameColumn( - name: "AuditCount_Operator", - table: "Store_CountPlanDetail", - newName: "FirstCountOperator"); - - migrationBuilder.RenameColumn( - name: "RepeatCount_Time", - table: "Store_CountNoteDetail", - newName: "RepeatCountTime"); - - migrationBuilder.RenameColumn( - name: "RepeatCount_Operator", - table: "Store_CountNoteDetail", - newName: "RepeatCountOperator"); - - migrationBuilder.RenameColumn( - name: "FirstCount_Time", - table: "Store_CountNoteDetail", - newName: "FirstCountTime"); - - migrationBuilder.RenameColumn( - name: "FirstCount_Operator", - table: "Store_CountNoteDetail", - newName: "RepeatCountDescription"); - - migrationBuilder.RenameColumn( - name: "AuditCount_Time", - table: "Store_CountNoteDetail", - newName: "AuditCountTime"); - - migrationBuilder.RenameColumn( - name: "AuditCount_Operator", - table: "Store_CountNoteDetail", - newName: "FirstCountOperator"); - - migrationBuilder.AddColumn( - name: "AuditCountDescription", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "AuditCountOperator", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "AuditCountQty", - table: "Store_CountPlanDetail", - type: "decimal(18,6)", - precision: 18, - scale: 6, - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "FirstCountDescription", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FirstCountQty", - table: "Store_CountPlanDetail", - type: "decimal(18,6)", - precision: 18, - scale: 6, - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RepeatCountQty", - table: "Store_CountPlanDetail", - type: "decimal(18,6)", - precision: 18, - scale: 6, - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "AuditCountDescription", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "AuditCountOperator", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "AuditCountQty", - table: "Store_CountNoteDetail", - type: "decimal(18,6)", - precision: 18, - scale: 6, - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "FirstCountDescription", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FirstCountQty", - table: "Store_CountNoteDetail", - type: "decimal(18,6)", - precision: 18, - scale: 6, - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RepeatCountQty", - table: "Store_CountNoteDetail", - type: "decimal(18,6)", - precision: 18, - scale: 6, - nullable: false, - defaultValue: 0m); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "AuditCountDescription", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "AuditCountOperator", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "AuditCountQty", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "FirstCountDescription", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "FirstCountQty", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "RepeatCountQty", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "AuditCountDescription", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "AuditCountOperator", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "AuditCountQty", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "FirstCountDescription", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "FirstCountQty", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "RepeatCountQty", - table: "Store_CountNoteDetail"); - - migrationBuilder.RenameColumn( - name: "ContactPhone", - table: "Store_SupplierAsn", - newName: "Contacts_Phone"); - - migrationBuilder.RenameColumn( - name: "ContactName", - table: "Store_SupplierAsn", - newName: "Contacts_Name"); - - migrationBuilder.RenameColumn( - name: "ContactEmail", - table: "Store_SupplierAsn", - newName: "Contacts_Email"); - - migrationBuilder.RenameColumn( - name: "ContactPhone", - table: "Store_SaleOrder", - newName: "Contacts_Phone"); - - migrationBuilder.RenameColumn( - name: "ContactName", - table: "Store_SaleOrder", - newName: "Contacts_Name"); - - migrationBuilder.RenameColumn( - name: "ContactEmail", - table: "Store_SaleOrder", - newName: "Contacts_Email"); - - migrationBuilder.RenameColumn( - name: "ContactPhone", - table: "Store_PurchaseOrder", - newName: "Contacts_Phone"); - - migrationBuilder.RenameColumn( - name: "ContactName", - table: "Store_PurchaseOrder", - newName: "Contacts_Name"); - - migrationBuilder.RenameColumn( - name: "ContactEmail", - table: "Store_PurchaseOrder", - newName: "Contacts_Email"); - - migrationBuilder.RenameColumn( - name: "InspectUser", - table: "Store_InspectNoteSummaryDetail", - newName: "InspectUser_Phone"); - - migrationBuilder.RenameColumn( - name: "InspectUser", - table: "Store_InspectNoteDetail", - newName: "InspectUser_Phone"); - - migrationBuilder.RenameColumn( - name: "ContactPhone", - table: "Store_CustomerAsn", - newName: "Contacts_Phone"); - - migrationBuilder.RenameColumn( - name: "ContactName", - table: "Store_CustomerAsn", - newName: "Contacts_Name"); - - migrationBuilder.RenameColumn( - name: "ContactEmail", - table: "Store_CustomerAsn", - newName: "Contacts_Email"); - - migrationBuilder.RenameColumn( - name: "RepeatCountTime", - table: "Store_CountPlanDetail", - newName: "RepeatCount_Time"); - - migrationBuilder.RenameColumn( - name: "RepeatCountOperator", - table: "Store_CountPlanDetail", - newName: "RepeatCount_Operator"); - - migrationBuilder.RenameColumn( - name: "RepeatCountDescription", - table: "Store_CountPlanDetail", - newName: "FirstCount_Operator"); - - migrationBuilder.RenameColumn( - name: "FirstCountTime", - table: "Store_CountPlanDetail", - newName: "FirstCount_Time"); - - migrationBuilder.RenameColumn( - name: "FirstCountOperator", - table: "Store_CountPlanDetail", - newName: "AuditCount_Operator"); - - migrationBuilder.RenameColumn( - name: "AuditCountTime", - table: "Store_CountPlanDetail", - newName: "AuditCount_Time"); - - migrationBuilder.RenameColumn( - name: "RepeatCountTime", - table: "Store_CountNoteDetail", - newName: "RepeatCount_Time"); - - migrationBuilder.RenameColumn( - name: "RepeatCountOperator", - table: "Store_CountNoteDetail", - newName: "RepeatCount_Operator"); - - migrationBuilder.RenameColumn( - name: "RepeatCountDescription", - table: "Store_CountNoteDetail", - newName: "FirstCount_Operator"); - - migrationBuilder.RenameColumn( - name: "FirstCountTime", - table: "Store_CountNoteDetail", - newName: "FirstCount_Time"); - - migrationBuilder.RenameColumn( - name: "FirstCountOperator", - table: "Store_CountNoteDetail", - newName: "AuditCount_Operator"); - - migrationBuilder.RenameColumn( - name: "AuditCountTime", - table: "Store_CountNoteDetail", - newName: "AuditCount_Time"); - - migrationBuilder.AddColumn( - name: "InspectUser_Email", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "InspectUser_Name", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "InspectUser_Email", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "InspectUser_Name", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "AuditCount_Description", - table: "Store_CountPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "AuditCount_Qty", - table: "Store_CountPlanDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FirstCount_Description", - table: "Store_CountPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "FirstCount_Qty", - table: "Store_CountPlanDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RepeatCount_Description", - table: "Store_CountPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "RepeatCount_Qty", - table: "Store_CountPlanDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "AuditCount_Description", - table: "Store_CountNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "AuditCount_Qty", - table: "Store_CountNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FirstCount_Description", - table: "Store_CountNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "FirstCount_Qty", - table: "Store_CountNoteDetail", - type: "decimal(18,6)", - nullable: true); - - migrationBuilder.AddColumn( - name: "RepeatCount_Description", - table: "Store_CountNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "RepeatCount_Qty", - table: "Store_CountNoteDetail", - type: "decimal(18,6)", - nullable: true); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230110065135_FlatLocation.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230110065135_FlatLocation.Designer.cs deleted file mode 100644 index 1dd2269d9..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230110065135_FlatLocation.Designer.cs +++ /dev/null @@ -1,15676 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230110065135_FlatLocation")] - partial class FlatLocation - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasColumnType("nvarchar(450)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RequestType") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromLocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreateType") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductL7PartsNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductL7PartsNoteDetailId"); - - b1.ToTable("Store_ProductL7PartsNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductL7PartsNoteDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ProductItem", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("ProductItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230110065135_FlatLocation.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230110065135_FlatLocation.cs deleted file mode 100644 index 377be7229..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230110065135_FlatLocation.cs +++ /dev/null @@ -1,4095 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class FlatLocation : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Store_ProductReceiptRequestDetail_Number_ItemCode_LocationCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductionReturnRequestDetail_Number_ItemCode_LocationCode", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_WorkOrder"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_WarehouseTransferNote"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptRequest"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptNote"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueRequest"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueNote"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_TransferRequest"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_TransferNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_SupplierAsn"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ScrapRequest"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ScrapNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_SaleOrder"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_RecycledMaterialReceiptNote"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ReceiptAbnormalNote"); - - migrationBuilder.DropColumn( - name: "ContainerCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "Lot", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "Status", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "Worker", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PutawayRequest"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "Worker", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PutawayNote"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnRequest"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnNote"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendErpCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseOrder"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "RawLocation_Area", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleRequest"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleNote"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptRequest"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductL7PartsNote"); - - migrationBuilder.DropColumn( - name: "ContainerCode", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "PoNumber", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "PoNumber", - table: "Store_ProductionReturnRequest"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductionReturnRequest"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "PoNumber", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "PoNumber", - table: "Store_ProductionReturnNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductionReturnNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductionPlan"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PreparationPlan"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_OfflineSettlementNote"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_NoOkConvertOkNote"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_MaterialRequest"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_JisDeliverNote"); - - migrationBuilder.DropColumn( - name: "LocationCode", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ItemTransformRequest"); - - migrationBuilder.DropColumn( - name: "LocationCode", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ItemTransformNote"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_IssueNote"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_IsolationNote"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InventoryTransferNote"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InventoryInitialNote"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InspectRequest"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InspectNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InspectAbnormalNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_DeliverRequest"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_DeliverPlan"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationCode", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_DeliverNote"); - - migrationBuilder.DropColumn( - name: "FromLocation_Area", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_ErpCode", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocation_Group", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Area", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_ErpCode", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocation_Group", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CustomerReturnNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CustomerAsn"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountPlan"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountNote"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountAdjustRequest"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountAdjustNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ContainerBindNote"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "Location_Area", - table: "Store_BackFlushNote"); - - migrationBuilder.DropColumn( - name: "Location_ErpCode", - table: "Store_BackFlushNote"); - - migrationBuilder.DropColumn( - name: "Location_Group", - table: "Store_BackFlushNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptRequest"); - - migrationBuilder.RenameColumn( - name: "RawLocation", - table: "Store_WorkOrderDetail", - newName: "RawLocationCode"); - - migrationBuilder.RenameColumn( - name: "ToLocation_Group", - table: "Store_PutawayRequestDetail", - newName: "PoNumber"); - - migrationBuilder.RenameColumn( - name: "ToLocation_ErpCode", - table: "Store_PutawayRequestDetail", - newName: "PoLine"); - - migrationBuilder.RenameColumn( - name: "PackingCode", - table: "Store_PutawayRequestDetail", - newName: "ToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "LocationCode", - table: "Store_PutawayRequestDetail", - newName: "FromLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RawLocation_Group", - table: "Store_ProductRecycleRequestDetail", - newName: "RawWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RawLocation_ErpCode", - table: "Store_ProductRecycleRequestDetail", - newName: "RawLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RawLocation", - table: "Store_ProductReceiptNoteDetail", - newName: "RawLocationCode"); - - migrationBuilder.RenameColumn( - name: "RawLocation", - table: "Store_ProductL7PartsNoteDetail", - newName: "RawLocationCode"); - - migrationBuilder.RenameColumn( - name: "ToLocation_Group", - table: "Store_ProductionReturnRequestDetail", - newName: "ToPackingCode"); - - migrationBuilder.RenameColumn( - name: "ToLocation_ErpCode", - table: "Store_ProductionReturnRequestDetail", - newName: "ToLot"); - - migrationBuilder.RenameColumn( - name: "ToLocation_Area", - table: "Store_ProductionReturnRequestDetail", - newName: "ToContainerCode"); - - migrationBuilder.RenameColumn( - name: "Status", - table: "Store_ProductionReturnRequestDetail", - newName: "ToStatus"); - - migrationBuilder.RenameColumn( - name: "PackingCode", - table: "Store_ProductionReturnRequestDetail", - newName: "ToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "Lot", - table: "Store_ProductionReturnRequestDetail", - newName: "FromPackingCode"); - - migrationBuilder.RenameColumn( - name: "Location_Group", - table: "Store_ProductionReturnRequestDetail", - newName: "FromLot"); - - migrationBuilder.RenameColumn( - name: "Location_ErpCode", - table: "Store_ProductionReturnRequestDetail", - newName: "FromContainerCode"); - - migrationBuilder.RenameColumn( - name: "LocationCode", - table: "Store_ProductionReturnRequestDetail", - newName: "ToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RawLocation", - table: "Store_JisProductReceiptNoteDetail", - newName: "WarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RawLocation", - table: "Store_JisProductReceiptNote", - newName: "RawLocationCode"); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "LocationCode", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocationCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "FromLocationCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromStatus", - table: "Store_ProductionReturnRequestDetail", - type: "int", - nullable: false, - defaultValue: 0); - - migrationBuilder.AddColumn( - name: "FromWarehouseCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWarehouseCode", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "RawLocationCode", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocationCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "FromLocationCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWarehouseCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWarehouseCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "ToLocationCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "FromLocationCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWarehouseCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWarehouseCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationErpCode", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationErpCode", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AlterColumn( - name: "WarehouseCode", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "LocationErpCode", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptRequestDetail_Number_ItemCode_LocationCode", - table: "Store_ProductReceiptRequestDetail", - columns: new[] { "Number", "ItemCode", "LocationCode" }, - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnRequestDetail_Number_ItemCode_FromLocationCode", - table: "Store_ProductionReturnRequestDetail", - columns: new[] { "Number", "ItemCode", "FromLocationCode" }, - unique: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Store_ProductReceiptRequestDetail_Number_ItemCode_LocationCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropIndex( - name: "IX_Store_ProductionReturnRequestDetail_Number_ItemCode_FromLocationCode", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationCode", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromStatus", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWarehouseCode", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWarehouseCode", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RawLocationCode", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationCode", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWarehouseCode", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWarehouseCode", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationCode", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWarehouseCode", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWarehouseCode", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationErpCode", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationErpCode", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationErpCode", - table: "Store_BackFlushNote"); - - migrationBuilder.RenameColumn( - name: "RawLocationCode", - table: "Store_WorkOrderDetail", - newName: "RawLocation"); - - migrationBuilder.RenameColumn( - name: "ToLocationErpCode", - table: "Store_PutawayRequestDetail", - newName: "PackingCode"); - - migrationBuilder.RenameColumn( - name: "PoNumber", - table: "Store_PutawayRequestDetail", - newName: "ToLocation_Group"); - - migrationBuilder.RenameColumn( - name: "PoLine", - table: "Store_PutawayRequestDetail", - newName: "ToLocation_ErpCode"); - - migrationBuilder.RenameColumn( - name: "FromLocationErpCode", - table: "Store_PutawayRequestDetail", - newName: "LocationCode"); - - migrationBuilder.RenameColumn( - name: "RawWarehouseCode", - table: "Store_ProductRecycleRequestDetail", - newName: "RawLocation_Group"); - - migrationBuilder.RenameColumn( - name: "RawLocationErpCode", - table: "Store_ProductRecycleRequestDetail", - newName: "RawLocation_ErpCode"); - - migrationBuilder.RenameColumn( - name: "RawLocationCode", - table: "Store_ProductReceiptNoteDetail", - newName: "RawLocation"); - - migrationBuilder.RenameColumn( - name: "RawLocationCode", - table: "Store_ProductL7PartsNoteDetail", - newName: "RawLocation"); - - migrationBuilder.RenameColumn( - name: "ToWarehouseCode", - table: "Store_ProductionReturnRequestDetail", - newName: "PackingCode"); - - migrationBuilder.RenameColumn( - name: "ToStatus", - table: "Store_ProductionReturnRequestDetail", - newName: "Status"); - - migrationBuilder.RenameColumn( - name: "ToPackingCode", - table: "Store_ProductionReturnRequestDetail", - newName: "ToLocation_Group"); - - migrationBuilder.RenameColumn( - name: "ToLot", - table: "Store_ProductionReturnRequestDetail", - newName: "ToLocation_ErpCode"); - - migrationBuilder.RenameColumn( - name: "ToLocationErpCode", - table: "Store_ProductionReturnRequestDetail", - newName: "LocationCode"); - - migrationBuilder.RenameColumn( - name: "ToContainerCode", - table: "Store_ProductionReturnRequestDetail", - newName: "ToLocation_Area"); - - migrationBuilder.RenameColumn( - name: "FromPackingCode", - table: "Store_ProductionReturnRequestDetail", - newName: "Lot"); - - migrationBuilder.RenameColumn( - name: "FromLot", - table: "Store_ProductionReturnRequestDetail", - newName: "Location_Group"); - - migrationBuilder.RenameColumn( - name: "FromContainerCode", - table: "Store_ProductionReturnRequestDetail", - newName: "Location_ErpCode"); - - migrationBuilder.RenameColumn( - name: "WarehouseCode", - table: "Store_JisProductReceiptNoteDetail", - newName: "RawLocation"); - - migrationBuilder.RenameColumn( - name: "RawLocationCode", - table: "Store_JisProductReceiptNote", - newName: "RawLocation"); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_WorkOrder", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_WarehouseTransferNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedReceiptNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_UnplannedIssueNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_TransferRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_TransferNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_SupplierAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ScrapRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ScrapNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_SaleOrder", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_RecycledMaterialReceiptNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ReceiptAbnormalNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "ContainerCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Lot", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Status", - table: "Store_PutawayRequestDetail", - type: "int", - nullable: false, - defaultValue: 0); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Worker", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PutawayRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Worker", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PutawayNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReturnNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendErpCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseOrder", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RawLocation_Area", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductRecycleNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationCode", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductReceiptRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductL7PartsNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "ContainerCode", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "PoNumber", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "PoNumber", - table: "Store_ProductionReturnRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductionReturnRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "PoNumber", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "PoNumber", - table: "Store_ProductionReturnNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductionReturnNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ProductionPlan", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PreparationPlan", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_OfflineSettlementNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_NoOkConvertOkNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_MaterialRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_JisDeliverNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "LocationCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ItemTransformRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "LocationCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ItemTransformNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_IssueNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_IsolationNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InventoryTransferNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InventoryInitialNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InspectRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InspectNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InspectAbnormalNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_DeliverRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_DeliverPlan", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocationCode", - table: "Store_DeliverNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_DeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_DeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_DeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_DeliverNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Area", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_ErpCode", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "FromLocation_Group", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Area", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_ErpCode", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToLocation_Group", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CustomerReturnNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CustomerAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountPlan", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountAdjustRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_CountAdjustNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_ContainerBindNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "WarehouseCode", - table: "Store_BackFlushNote", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Location_Area", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_ErpCode", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "Location_Group", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductReceiptRequestDetail_Number_ItemCode_LocationCode", - table: "Store_ProductReceiptRequestDetail", - columns: new[] { "Number", "ItemCode", "LocationCode" }, - unique: true, - filter: "[LocationCode] IS NOT NULL"); - - migrationBuilder.CreateIndex( - name: "IX_Store_ProductionReturnRequestDetail_Number_ItemCode_LocationCode", - table: "Store_ProductionReturnRequestDetail", - columns: new[] { "Number", "ItemCode", "LocationCode" }, - unique: true); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111060139_ResumeLocationAreaAndLocationGroup.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111060139_ResumeLocationAreaAndLocationGroup.Designer.cs deleted file mode 100644 index 06f036230..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111060139_ResumeLocationAreaAndLocationGroup.Designer.cs +++ /dev/null @@ -1,16773 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230111060139_ResumeLocationAreaAndLocationGroup")] - partial class ResumeLocationAreaAndLocationGroup - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasColumnType("nvarchar(450)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RequestType") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromLocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreateType") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("WorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WorkGroup"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("FromWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWorkGroup"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("ToWorkGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWorkGroup"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductL7PartsNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductL7PartsNoteDetailId"); - - b1.ToTable("Store_ProductL7PartsNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductL7PartsNoteDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ProductItem", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("ProductItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111060139_ResumeLocationAreaAndLocationGroup.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111060139_ResumeLocationAreaAndLocationGroup.cs deleted file mode 100644 index 1c1f5780a..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111060139_ResumeLocationAreaAndLocationGroup.cs +++ /dev/null @@ -1,2196 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class ResumeLocationAreaAndLocationGroup : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "RawLocationArea", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RawLocationGroup", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationArea", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromLocationGroup", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationArea", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToLocationGroup", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationArea", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "LocationGroup", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "RawLocationArea", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "RawLocationGroup", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationArea", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromLocationGroup", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationArea", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToLocationGroup", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "LocationArea", - table: "Store_BackFlushNote"); - - migrationBuilder.DropColumn( - name: "LocationGroup", - table: "Store_BackFlushNote"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_BackFlushNote"); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111071618_RemoveWorkGroup.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111071618_RemoveWorkGroup.Designer.cs deleted file mode 100644 index 4c4cf945d..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111071618_RemoveWorkGroup.Designer.cs +++ /dev/null @@ -1,16410 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230111071618_RemoveWorkGroup")] - partial class RemoveWorkGroup - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasColumnType("nvarchar(450)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RequestType") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromLocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .HasColumnType("nvarchar(max)"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreateType") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Reason") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteId"); - - b1.ToTable("Store_BackFlushNote"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("BackFlushNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("BackFlushNoteDetailId"); - - b1.ToTable("Store_BackFlushNoteDetail"); - - b1.WithOwner() - .HasForeignKey("BackFlushNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ContainerBindNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ContainerBindNoteDetailId"); - - b1.ToTable("Store_ContainerBindNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ContainerBindNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustNoteDetailId"); - - b1.ToTable("Store_CountAdjustNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountAdjustRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountAdjustRequestDetailId"); - - b1.ToTable("Store_CountAdjustRequestDetail"); - - b1.WithOwner() - .HasForeignKey("CountAdjustRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountNoteDetailId"); - - b1.ToTable("Store_CountNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CountNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CountPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CountPlanDetailId"); - - b1.ToTable("Store_CountPlanDetail"); - - b1.WithOwner() - .HasForeignKey("CountPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerAsnDetailId"); - - b1.ToTable("Store_CustomerAsnDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerAsnDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("CustomerReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("CustomerReturnNoteDetailId"); - - b1.ToTable("Store_CustomerReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("CustomerReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverNoteDetailId"); - - b1.ToTable("Store_DeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverPlanDetailId"); - - b1.ToTable("Store_DeliverPlanDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("DeliverRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("DeliverRequestDetailId"); - - b1.ToTable("Store_DeliverRequestDetail"); - - b1.WithOwner() - .HasForeignKey("DeliverRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectAbnormalNoteDetailId"); - - b1.ToTable("Store_InspectAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteDetailId"); - - b1.ToTable("Store_InspectNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectNoteSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectNoteSummaryDetailId"); - - b1.ToTable("Store_InspectNoteSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectNoteSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestDetailId"); - - b1.ToTable("Store_InspectRequestDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InspectRequestSummaryDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InspectRequestSummaryDetailId"); - - b1.ToTable("Store_InspectRequestSummaryDetail"); - - b1.WithOwner() - .HasForeignKey("InspectRequestSummaryDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryInitialNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryInitialNoteDetailId"); - - b1.ToTable("Store_InventoryInitialNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryInitialNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("InventoryTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("InventoryTransferNoteDetailId"); - - b1.ToTable("Store_InventoryTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("InventoryTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IsolationNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IsolationNoteDetailId"); - - b1.ToTable("Store_IsolationNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IsolationNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("IssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("IssueNoteDetailId"); - - b1.ToTable("Store_IssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("IssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformNoteDetailId"); - - b1.ToTable("Store_ItemTransformNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformNoteDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "FromBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "ToBatch", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ToItem", b1 => - { - b1.Property("ItemTransformRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ItemTransformRequestDetailId"); - - b1.ToTable("Store_ItemTransformRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ItemTransformRequestDetailId"); - }); - - b.Navigation("FromBatch"); - - b.Navigation("Item"); - - b.Navigation("ToBatch"); - - b.Navigation("ToItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisDeliverNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisDeliverNoteDetailId"); - - b1.ToTable("Store_JisDeliverNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisDeliverNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("JisProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("JisProductReceiptNoteDetailId"); - - b1.ToTable("Store_JisProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("JisProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("MaterialRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("MaterialRequestDetailId"); - - b1.ToTable("Store_MaterialRequestDetail"); - - b1.WithOwner() - .HasForeignKey("MaterialRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("NoOkConvertOkNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("NoOkConvertOkNoteDetailId"); - - b1.ToTable("Store_NoOkConvertOkNoteDetail"); - - b1.WithOwner() - .HasForeignKey("NoOkConvertOkNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("OfflineSettlementNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("OfflineSettlementNoteDetailId"); - - b1.ToTable("Store_OfflineSettlementNoteDetail"); - - b1.WithOwner() - .HasForeignKey("OfflineSettlementNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PreparationPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PreparationPlanDetailId"); - - b1.ToTable("Store_PreparationPlanDetail"); - - b1.WithOwner() - .HasForeignKey("PreparationPlanDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionPlanDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionPlanDetailId"); - - b1.ToTable("Store_ProductionPlanDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionPlanDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnNoteDetailId"); - - b1.ToTable("Store_ProductionReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductionReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductionReturnRequestDetailId"); - - b1.ToTable("Store_ProductionReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductionReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductL7PartsNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductL7PartsNoteDetailId"); - - b1.ToTable("Store_ProductL7PartsNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductL7PartsNoteDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptNoteDetailId"); - - b1.ToTable("Store_ProductReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductReceiptRequestDetailId"); - - b1.ToTable("Store_ProductReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "ProductItem", b1 => - { - b1.Property("ProductRecycleMaterialDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleMaterialDetailId"); - - b1.ToTable("Store_ProductRecycleMaterialDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleMaterialDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - - b.Navigation("ProductItem"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleNoteDetailId"); - - b1.ToTable("Store_ProductRecycleNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ProductRecycleRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ProductRecycleRequestDetailId"); - - b1.ToTable("Store_ProductRecycleRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ProductRecycleRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseOrderDetailId"); - - b1.ToTable("Store_PurchaseOrderDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptNoteDetailId"); - - b1.ToTable("Store_PurchaseReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReceiptRequestDetailId"); - - b1.ToTable("Store_PurchaseReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnNoteDetailId"); - - b1.ToTable("Store_PurchaseReturnNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PurchaseReturnRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PurchaseReturnRequestDetailId"); - - b1.ToTable("Store_PurchaseReturnRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PurchaseReturnRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayNoteDetailId"); - - b1.ToTable("Store_PutawayNoteDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("PutawayRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("PutawayRequestDetailId"); - - b1.ToTable("Store_PutawayRequestDetail"); - - b1.WithOwner() - .HasForeignKey("PutawayRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ReceiptAbnormalNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ReceiptAbnormalNoteDetailId"); - - b1.ToTable("Store_ReceiptAbnormalNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ReceiptAbnormalNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("RecycledMaterialReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("RecycledMaterialReceiptNoteDetailId"); - - b1.ToTable("Store_RecycledMaterialReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("RecycledMaterialReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SaleOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SaleOrderDetailId"); - - b1.ToTable("Store_SaleOrderDetail"); - - b1.WithOwner() - .HasForeignKey("SaleOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapNoteDetailId"); - - b1.ToTable("Store_ScrapNoteDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("ScrapRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("ScrapRequestDetailId"); - - b1.ToTable("Store_ScrapRequestDetail"); - - b1.WithOwner() - .HasForeignKey("ScrapRequestDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("SupplierAsnDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("SupplierAsnDetailId"); - - b1.ToTable("Store_SupplierAsnDetail"); - - b1.WithOwner() - .HasForeignKey("SupplierAsnDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferNoteDetailId"); - - b1.ToTable("Store_TransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("TransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("TransferRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("TransferRequestDetailId"); - - b1.ToTable("Store_TransferRequestDetail"); - - b1.WithOwner() - .HasForeignKey("TransferRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueNoteDetailId"); - - b1.ToTable("Store_UnplannedIssueNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedIssueRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedIssueRequestDetailId"); - - b1.ToTable("Store_UnplannedIssueRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedIssueRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptNoteDetailId"); - - b1.ToTable("Store_UnplannedReceiptNoteDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("UnplannedReceiptRequestDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("UnplannedReceiptRequestDetailId"); - - b1.ToTable("Store_UnplannedReceiptRequestDetail"); - - b1.WithOwner() - .HasForeignKey("UnplannedReceiptRequestDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Batch", "Batch", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("ArriveDate") - .HasColumnType("datetime2"); - - b1.Property("ExpireDate") - .HasColumnType("datetime2"); - - b1.Property("ProduceDate") - .HasColumnType("datetime2"); - - b1.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WarehouseTransferNoteDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WarehouseTransferNoteDetailId"); - - b1.ToTable("Store_WarehouseTransferNoteDetail"); - - b1.WithOwner() - .HasForeignKey("WarehouseTransferNoteDetailId"); - }); - - b.Navigation("Batch"); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderId"); - - b1.ToTable("Store_WorkOrder"); - - b1.WithOwner() - .HasForeignKey("WorkOrderId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - - b.OwnsOne("Win_in.Sfs.Shared.Domain.Item", "Item", b1 => - { - b1.Property("WorkOrderDetailId") - .HasColumnType("uniqueidentifier"); - - b1.Property("Desc1") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Desc2") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b1.Property("Name") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b1.HasKey("WorkOrderDetailId"); - - b1.ToTable("Store_WorkOrderDetail"); - - b1.WithOwner() - .HasForeignKey("WorkOrderDetailId"); - }); - - b.Navigation("Item"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111071618_RemoveWorkGroup.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111071618_RemoveWorkGroup.cs deleted file mode 100644 index d3ba352fd..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230111071618_RemoveWorkGroup.cs +++ /dev/null @@ -1,734 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class RemoveWorkGroup : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromWorkGroup", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToWorkGroup", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "WorkGroup", - table: "Store_BackFlushNote"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "FromWorkGroup", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "ToWorkGroup", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - - migrationBuilder.AddColumn( - name: "WorkGroup", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: ""); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230112071932_FlatItemAndBatch.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230112071932_FlatItemAndBatch.Designer.cs deleted file mode 100644 index 83f7fc8fa..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230112071932_FlatItemAndBatch.Designer.cs +++ /dev/null @@ -1,14974 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230112071932_FlatItemAndBatch")] - partial class FlatItemAndBatch - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RequestType") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromArriveDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromProduceDate") - .HasColumnType("datetime2"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToArriveDate") - .HasColumnType("datetime2"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToExpireDate") - .HasColumnType("datetime2"); - - b.Property("ToItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToProduceDate") - .HasColumnType("datetime2"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromArriveDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromProduceDate") - .HasColumnType("datetime2"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToArriveDate") - .HasColumnType("datetime2"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToExpireDate") - .HasColumnType("datetime2"); - - b.Property("ToItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToProduceDate") - .HasColumnType("datetime2"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromLocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreateType") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230112071932_FlatItemAndBatch.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230112071932_FlatItemAndBatch.cs deleted file mode 100644 index da3dc7637..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230112071932_FlatItemAndBatch.cs +++ /dev/null @@ -1,11937 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class FlatItemAndBatch : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Store_BackFlushNoteDetail_Number_ItemCode_Lot", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_WorkOrderDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_WorkOrderDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_WorkOrder"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_WorkOrder"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "Batch_ArriveDate", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "ProductItem_Desc1", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "ProductItem_Desc2", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ProductL7PartsNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ProductL7PartsNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ProductionPlanDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ProductionPlanDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_PreparationPlanDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_PreparationPlanDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromBatch_ArriveDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromBatch_ExpireDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromBatch_ProduceDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToBatch_ArriveDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToBatch_ExpireDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToBatch_ProduceDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToItem_Desc1", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToItem_Desc2", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromBatch_ArriveDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromBatch_ExpireDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromBatch_ProduceDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToBatch_ArriveDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToBatch_ExpireDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToBatch_ProduceDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToItem_Desc1", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToItem_Desc2", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_InspectAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_InspectAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_DeliverPlanDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_DeliverPlanDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_CustomerAsnDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_CustomerAsnDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_ContainerBindNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_ContainerBindNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "Item_Desc1", - table: "Store_BackFlushNote"); - - migrationBuilder.DropColumn( - name: "Item_Desc2", - table: "Store_BackFlushNote"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_WorkOrderDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_WorkOrder", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_WarehouseTransferNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_WarehouseTransferNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_WarehouseTransferNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_WarehouseTransferNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_WarehouseTransferNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedReceiptRequestDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_UnplannedReceiptRequestDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_UnplannedReceiptRequestDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_UnplannedReceiptRequestDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_UnplannedReceiptRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedReceiptNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_UnplannedReceiptNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_UnplannedReceiptNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_UnplannedReceiptNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_UnplannedReceiptNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedIssueRequestDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_UnplannedIssueRequestDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_UnplannedIssueRequestDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_UnplannedIssueRequestDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_UnplannedIssueRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_UnplannedIssueNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_UnplannedIssueNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_UnplannedIssueNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_UnplannedIssueNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_UnplannedIssueNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_TransferRequestDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_TransferRequestDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_TransferRequestDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_TransferRequestDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_TransferRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_TransferNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_TransferNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_TransferNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_TransferNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_TransferNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_SupplierAsnDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_SupplierAsnDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_SupplierAsnDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_SupplierAsnDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_SupplierAsnDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ScrapRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_ScrapNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_ScrapNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_ScrapNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_ScrapNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ScrapNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_SaleOrderDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_PutawayRequestDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_PutawayRequestDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_PutawayRequestDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_PutawayRequestDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_PutawayRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_PutawayNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_PutawayNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_PutawayNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_PutawayNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_PutawayNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReturnRequestDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_PurchaseReturnRequestDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_PurchaseReturnRequestDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_PurchaseReturnRequestDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_PurchaseReturnRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReturnNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_PurchaseReturnNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_PurchaseReturnNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_PurchaseReturnNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_PurchaseReturnNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReceiptRequestDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_PurchaseReceiptRequestDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_PurchaseReceiptRequestDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_PurchaseReceiptRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_PurchaseReceiptNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_PurchaseReceiptNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_PurchaseReceiptNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_PurchaseReceiptNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_PurchaseReceiptNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_PurchaseOrderDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ProductRecycleRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductRecycleNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_ProductRecycleNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_ProductRecycleNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_ProductRecycleNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ProductRecycleNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductRecycleMaterialDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_ProductRecycleMaterialDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_ProductRecycleMaterialDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_ProductRecycleMaterialDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ProductItem_Name", - table: "Store_ProductRecycleMaterialDetail", - newName: "ProductItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ProductRecycleMaterialDetail", - newName: "ProductItemDesc2"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductReceiptRequestDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_ProductReceiptRequestDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_ProductReceiptRequestDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_ProductReceiptRequestDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ProductReceiptRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductReceiptNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_ProductReceiptNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_ProductReceiptNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_ProductReceiptNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ProductReceiptNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ProductL7PartsNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductionReturnRequestDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_ProductionReturnRequestDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_ProductionReturnRequestDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_ProductionReturnRequestDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ProductionReturnRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductionReturnNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_ProductionReturnNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_ProductionReturnNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_ProductionReturnNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ProductionReturnNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_ProductionPlanDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_ProductionPlanDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_ProductionPlanDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_ProductionPlanDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ProductionPlanDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_PreparationPlanDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_OfflineSettlementNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_OfflineSettlementNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_OfflineSettlementNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_OfflineSettlementNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_OfflineSettlementNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_NoOkConvertOkNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_NoOkConvertOkNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_NoOkConvertOkNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_NoOkConvertOkNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_NoOkConvertOkNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_MaterialRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_JisProductReceiptNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_JisProductReceiptNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_JisProductReceiptNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_JisProductReceiptNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_JisProductReceiptNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_JisDeliverNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_JisDeliverNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_JisDeliverNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_JisDeliverNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_JisDeliverNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "ToItem_Name", - table: "Store_ItemTransformRequestDetail", - newName: "ToSupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ToBatch_SupplierBatch", - table: "Store_ItemTransformRequestDetail", - newName: "ToItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ItemTransformRequestDetail", - newName: "ToItemDesc2"); - - migrationBuilder.RenameColumn( - name: "FromBatch_SupplierBatch", - table: "Store_ItemTransformRequestDetail", - newName: "ToItemDesc1"); - - migrationBuilder.RenameColumn( - name: "ToItem_Name", - table: "Store_ItemTransformNoteDetail", - newName: "ToSupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ToBatch_SupplierBatch", - table: "Store_ItemTransformNoteDetail", - newName: "ToItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ItemTransformNoteDetail", - newName: "ToItemDesc2"); - - migrationBuilder.RenameColumn( - name: "FromBatch_SupplierBatch", - table: "Store_ItemTransformNoteDetail", - newName: "ToItemDesc1"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_IssueNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_IssueNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_IssueNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_IssueNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_IssueNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_IsolationNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_IsolationNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_IsolationNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_IsolationNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_IsolationNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_InventoryTransferNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_InventoryTransferNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_InventoryTransferNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_InventoryTransferNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_InventoryTransferNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_InventoryInitialNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_InventoryInitialNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_InventoryInitialNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_InventoryInitialNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_InventoryInitialNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectRequestSummaryDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_InspectRequestSummaryDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_InspectRequestSummaryDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_InspectRequestSummaryDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_InspectRequestSummaryDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectRequestDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_InspectRequestDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_InspectRequestDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_InspectRequestDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_InspectRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectNoteSummaryDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_InspectNoteSummaryDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_InspectNoteSummaryDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_InspectNoteSummaryDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_InspectNoteSummaryDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_InspectNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_InspectNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_InspectNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_InspectNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_InspectAbnormalNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_InspectAbnormalNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_InspectAbnormalNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_InspectAbnormalNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_InspectAbnormalNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_DeliverRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_DeliverPlanDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_DeliverNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_DeliverNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_DeliverNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_DeliverNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_DeliverNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_CustomerReturnNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_CustomerReturnNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_CustomerReturnNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_CustomerReturnNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_CustomerReturnNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_CustomerAsnDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_CountPlanDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_CountPlanDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_CountPlanDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_CountPlanDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_CountPlanDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_CountNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_CountNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_CountNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_CountNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_CountNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_CountAdjustRequestDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_CountAdjustRequestDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_CountAdjustRequestDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_CountAdjustRequestDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_CountAdjustRequestDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_CountAdjustNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_CountAdjustNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_CountAdjustNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_CountAdjustNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_CountAdjustNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_ContainerBindNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_ContainerBindNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_ContainerBindNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_ContainerBindNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_ContainerBindNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_BackFlushNoteDetail", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_BackFlushNoteDetail", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_BackFlushNoteDetail", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_BackFlushNoteDetail", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_BackFlushNoteDetail", - newName: "ItemName"); - - migrationBuilder.RenameColumn( - name: "Batch_SupplierBatch", - table: "Store_BackFlushNote", - newName: "SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "Batch_ProduceDate", - table: "Store_BackFlushNote", - newName: "ProduceDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ExpireDate", - table: "Store_BackFlushNote", - newName: "ExpireDate"); - - migrationBuilder.RenameColumn( - name: "Batch_ArriveDate", - table: "Store_BackFlushNote", - newName: "ArriveDate"); - - migrationBuilder.RenameColumn( - name: "Item_Name", - table: "Store_BackFlushNote", - newName: "ItemName"); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_WorkOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_WorkOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ItemCode", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Reason", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_WarehouseTransferNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_WarehouseTransferNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_WarehouseTransferNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_UnplannedReceiptRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_UnplannedReceiptRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_UnplannedReceiptRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_UnplannedIssueRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_UnplannedIssueRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_UnplannedIssueRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_TransferRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_TransferRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_TransferRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Reason", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_TransferNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_TransferNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_TransferNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_SupplierAsnDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_SupplierAsnDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_SupplierAsnDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "TimeWindow", - table: "Store_SupplierAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_ScrapNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_ScrapNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_ScrapNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_ReceiptAbnormalNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_ReceiptAbnormalNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_ReceiptAbnormalNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_PurchaseReturnRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_PurchaseReturnRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_PurchaseReturnRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Reason", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_PurchaseReceiptRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_PurchaseReceiptRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "TimeWindow", - table: "Store_PurchaseReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_ProductRecycleNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_ProductRecycleNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_ProductRecycleNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_ProductRecycleMaterialDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_ProductRecycleMaterialDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_ProductRecycleMaterialDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemName", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ProductItemDesc1", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_ProductReceiptRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_ProductReceiptRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_ProductReceiptRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "ItemCode", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_ProductionReturnRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_ProductionReturnRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_ProductionReturnRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_ProductionPlanDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_ProductionPlanDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_ProductionPlanDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ProductionPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ProductionPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PreparationPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_PreparationPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_PreparationPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_OfflineSettlementNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_OfflineSettlementNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_OfflineSettlementNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_NoOkConvertOkNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_NoOkConvertOkNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_NoOkConvertOkNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_JisProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_JisProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_JisProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_JisDeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_JisDeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_JisDeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToItemCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "FromArriveDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "FromExpireDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "FromProduceDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "FromSupplierBatch", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemName", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToArriveDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "ToExpireDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "ToProduceDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToItemCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "FromArriveDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "FromExpireDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "FromProduceDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "FromSupplierBatch", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemName", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToArriveDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "ToExpireDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "ToProduceDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_IsolationNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_IsolationNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_IsolationNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Reason", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_InventoryTransferNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_InventoryTransferNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_InventoryTransferNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_InventoryInitialNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_InventoryInitialNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_InventoryInitialNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_InspectRequestSummaryDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_InspectRequestSummaryDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_InspectRequestSummaryDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_InspectRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_InspectRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_InspectRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_InspectNoteSummaryDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_InspectNoteSummaryDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_InspectNoteSummaryDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_InspectNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_InspectNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_InspectNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_InspectAbnormalNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_InspectAbnormalNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_InspectAbnormalNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_DeliverRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_DeliverRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_DeliverRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_DeliverPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_DeliverPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_DeliverPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_CustomerReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_CustomerReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_CustomerReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_CustomerAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_CustomerAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_CustomerAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_CountPlanDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_CountPlanDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_CountPlanDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_CountNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_CountNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_CountNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_CountAdjustRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_CountAdjustRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_CountAdjustRequestDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_CountAdjustNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_CountAdjustNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_CountAdjustNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_ContainerBindNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_ContainerBindNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_ContainerBindNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "PackingCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Lot", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ItemCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ContainerCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_BackFlushNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_BackFlushNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_BackFlushNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProduceDate", - table: "Store_BackFlushNote", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ExpireDate", - table: "Store_BackFlushNote", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ArriveDate", - table: "Store_BackFlushNote", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified), - oldClrType: typeof(DateTime), - oldType: "datetime2", - oldNullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc1", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "ItemDesc2", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_BackFlushNoteDetail_Number_ItemCode_Lot", - table: "Store_BackFlushNoteDetail", - columns: new[] { "Number", "ItemCode", "Lot" }, - unique: true, - filter: "[Lot] IS NOT NULL"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropIndex( - name: "IX_Store_BackFlushNoteDetail_Number_ItemCode_Lot", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_WorkOrderDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_WorkOrderDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_WorkOrder"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_WorkOrder"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_WarehouseTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_UnplannedReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_UnplannedIssueRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_TransferRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_TransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_SupplierAsnDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ScrapRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ScrapNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_SaleOrderDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_RecycledMaterialReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ReceiptAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_PutawayRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_PurchaseReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_PurchaseReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ProductRecycleRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ProductRecycleNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "ItemName", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "ProductItemDesc1", - table: "Store_ProductRecycleMaterialDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ProductReceiptRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ProductL7PartsNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ProductL7PartsNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ProductionReturnRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ProductionPlanDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ProductionPlanDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_PreparationPlanDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_PreparationPlanDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_OfflineSettlementNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_NoOkConvertOkNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_MaterialRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_JisProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_JisDeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromArriveDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromExpireDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromProduceDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromSupplierBatch", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemName", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToArriveDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToExpireDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "ToProduceDate", - table: "Store_ItemTransformRequestDetail"); - - migrationBuilder.DropColumn( - name: "FromArriveDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromExpireDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromProduceDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "FromSupplierBatch", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemName", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToArriveDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToExpireDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ToProduceDate", - table: "Store_ItemTransformNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_IsolationNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_InventoryTransferNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_InventoryInitialNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_InspectRequestSummaryDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_InspectRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_InspectNoteSummaryDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_InspectNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_InspectAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_InspectAbnormalNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_DeliverRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_DeliverPlanDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_DeliverPlanDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_CustomerReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_CustomerAsnDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_CustomerAsnDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_CountPlanDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_CountNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_CountAdjustRequestDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_CountAdjustNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_ContainerBindNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_ContainerBindNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_BackFlushNoteDetail"); - - migrationBuilder.DropColumn( - name: "ItemDesc1", - table: "Store_BackFlushNote"); - - migrationBuilder.DropColumn( - name: "ItemDesc2", - table: "Store_BackFlushNote"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_WorkOrderDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_WorkOrder", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_WarehouseTransferNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_WarehouseTransferNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_WarehouseTransferNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_WarehouseTransferNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_WarehouseTransferNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_UnplannedReceiptRequestDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_UnplannedReceiptRequestDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_UnplannedReceiptRequestDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_UnplannedReceiptRequestDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_UnplannedReceiptRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_UnplannedReceiptNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_UnplannedReceiptNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_UnplannedReceiptNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_UnplannedReceiptNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_UnplannedReceiptNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_UnplannedIssueRequestDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_UnplannedIssueRequestDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_UnplannedIssueRequestDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_UnplannedIssueRequestDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_UnplannedIssueRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_UnplannedIssueNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_UnplannedIssueNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_UnplannedIssueNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_UnplannedIssueNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_UnplannedIssueNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_TransferRequestDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_TransferRequestDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_TransferRequestDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_TransferRequestDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_TransferRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_TransferNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_TransferNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_TransferNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_TransferNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_TransferNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_SupplierAsnDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_SupplierAsnDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_SupplierAsnDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_SupplierAsnDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_SupplierAsnDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ScrapRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_ScrapNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_ScrapNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_ScrapNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_ScrapNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ScrapNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_SaleOrderDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_RecycledMaterialReceiptNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ReceiptAbnormalNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_PutawayRequestDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_PutawayRequestDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_PutawayRequestDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_PutawayRequestDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_PutawayRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_PutawayNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_PutawayNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_PutawayNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_PutawayNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_PutawayNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_PurchaseReturnRequestDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_PurchaseReturnRequestDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_PurchaseReturnRequestDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_PurchaseReturnRequestDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_PurchaseReturnRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_PurchaseReturnNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_PurchaseReturnNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_PurchaseReturnNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_PurchaseReturnNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_PurchaseReturnNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_PurchaseReceiptRequestDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_PurchaseReceiptRequestDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_PurchaseReceiptRequestDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_PurchaseReceiptRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_PurchaseReceiptNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_PurchaseReceiptNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_PurchaseReceiptNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_PurchaseReceiptNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_PurchaseReceiptNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_PurchaseOrderDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ProductRecycleRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_ProductRecycleNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_ProductRecycleNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_ProductRecycleNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_ProductRecycleNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ProductRecycleNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_ProductRecycleMaterialDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_ProductRecycleMaterialDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_ProductRecycleMaterialDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_ProductRecycleMaterialDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ProductItemName", - table: "Store_ProductRecycleMaterialDetail", - newName: "ProductItem_Name"); - - migrationBuilder.RenameColumn( - name: "ProductItemDesc2", - table: "Store_ProductRecycleMaterialDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_ProductReceiptRequestDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_ProductReceiptRequestDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_ProductReceiptRequestDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_ProductReceiptRequestDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ProductReceiptRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_ProductReceiptNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_ProductReceiptNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_ProductReceiptNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_ProductReceiptNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ProductReceiptNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ProductL7PartsNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_ProductionReturnRequestDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_ProductionReturnRequestDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_ProductionReturnRequestDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_ProductionReturnRequestDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ProductionReturnRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_ProductionReturnNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_ProductionReturnNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_ProductionReturnNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_ProductionReturnNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ProductionReturnNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_ProductionPlanDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_ProductionPlanDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_ProductionPlanDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_ProductionPlanDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ProductionPlanDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_PreparationPlanDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_OfflineSettlementNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_OfflineSettlementNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_OfflineSettlementNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_OfflineSettlementNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_OfflineSettlementNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_NoOkConvertOkNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_NoOkConvertOkNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_NoOkConvertOkNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_NoOkConvertOkNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_NoOkConvertOkNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_MaterialRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_JisProductReceiptNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_JisProductReceiptNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_JisProductReceiptNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_JisProductReceiptNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_JisProductReceiptNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_JisDeliverNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_JisDeliverNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_JisDeliverNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_JisDeliverNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_JisDeliverNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ToSupplierBatch", - table: "Store_ItemTransformRequestDetail", - newName: "ToItem_Name"); - - migrationBuilder.RenameColumn( - name: "ToItemName", - table: "Store_ItemTransformRequestDetail", - newName: "ToBatch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ToItemDesc2", - table: "Store_ItemTransformRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ToItemDesc1", - table: "Store_ItemTransformRequestDetail", - newName: "FromBatch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ToSupplierBatch", - table: "Store_ItemTransformNoteDetail", - newName: "ToItem_Name"); - - migrationBuilder.RenameColumn( - name: "ToItemName", - table: "Store_ItemTransformNoteDetail", - newName: "ToBatch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ToItemDesc2", - table: "Store_ItemTransformNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ToItemDesc1", - table: "Store_ItemTransformNoteDetail", - newName: "FromBatch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_IssueNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_IssueNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_IssueNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_IssueNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_IssueNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_IsolationNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_IsolationNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_IsolationNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_IsolationNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_IsolationNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_InventoryTransferNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_InventoryTransferNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_InventoryTransferNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_InventoryTransferNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_InventoryTransferNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_InventoryInitialNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_InventoryInitialNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_InventoryInitialNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_InventoryInitialNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_InventoryInitialNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_InspectRequestSummaryDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_InspectRequestSummaryDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_InspectRequestSummaryDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_InspectRequestSummaryDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_InspectRequestSummaryDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_InspectRequestDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_InspectRequestDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_InspectRequestDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_InspectRequestDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_InspectRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_InspectNoteSummaryDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_InspectNoteSummaryDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_InspectNoteSummaryDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_InspectNoteSummaryDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_InspectNoteSummaryDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_InspectNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_InspectNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_InspectNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_InspectNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_InspectNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_InspectAbnormalNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_InspectAbnormalNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_InspectAbnormalNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_InspectAbnormalNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_InspectAbnormalNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_DeliverRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_DeliverPlanDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_DeliverNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_DeliverNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_DeliverNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_DeliverNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_DeliverNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_CustomerReturnNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_CustomerReturnNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_CustomerReturnNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_CustomerReturnNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_CustomerReturnNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_CustomerAsnDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_CountPlanDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_CountPlanDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_CountPlanDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_CountPlanDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_CountPlanDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_CountNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_CountNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_CountNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_CountNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_CountNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_CountAdjustRequestDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_CountAdjustRequestDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_CountAdjustRequestDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_CountAdjustRequestDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_CountAdjustRequestDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_CountAdjustNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_CountAdjustNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_CountAdjustNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_CountAdjustNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_CountAdjustNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_ContainerBindNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_ContainerBindNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_ContainerBindNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_ContainerBindNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_ContainerBindNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_BackFlushNoteDetail", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_BackFlushNoteDetail", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_BackFlushNoteDetail", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_BackFlushNoteDetail", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_BackFlushNoteDetail", - newName: "Item_Name"); - - migrationBuilder.RenameColumn( - name: "SupplierBatch", - table: "Store_BackFlushNote", - newName: "Batch_SupplierBatch"); - - migrationBuilder.RenameColumn( - name: "ProduceDate", - table: "Store_BackFlushNote", - newName: "Batch_ProduceDate"); - - migrationBuilder.RenameColumn( - name: "ExpireDate", - table: "Store_BackFlushNote", - newName: "Batch_ExpireDate"); - - migrationBuilder.RenameColumn( - name: "ArriveDate", - table: "Store_BackFlushNote", - newName: "Batch_ArriveDate"); - - migrationBuilder.RenameColumn( - name: "ItemName", - table: "Store_BackFlushNote", - newName: "Item_Name"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_WorkOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_WorkOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ItemCode", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_WorkOrder", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_WorkOrder", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Reason", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_WarehouseTransferNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_WarehouseTransferNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_WarehouseTransferNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_UnplannedReceiptRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_UnplannedReceiptRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_UnplannedReceiptRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_UnplannedIssueRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_UnplannedIssueRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_UnplannedIssueRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_TransferRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_TransferRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_TransferRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_TransferRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_TransferRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Reason", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_TransferNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_TransferNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_TransferNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_TransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_TransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_SupplierAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_SupplierAsnDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_SupplierAsnDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_SupplierAsnDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_SupplierAsnDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_SupplierAsnDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "TimeWindow", - table: "Store_SupplierAsn", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ScrapRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ScrapRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ScrapRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_ScrapNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_ScrapNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_ScrapNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ScrapNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ScrapNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_SaleOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_SaleOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_ReceiptAbnormalNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_ReceiptAbnormalNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_ReceiptAbnormalNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_PutawayRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_PutawayRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_PutawayRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_PutawayNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_PutawayNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_PurchaseReturnRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_PurchaseReturnRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_PurchaseReturnRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Reason", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_PurchaseReceiptRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_PurchaseReceiptRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Batch_ArriveDate", - table: "Store_PurchaseReceiptRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "TimeWindow", - table: "Store_PurchaseReceiptRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_ProductRecycleNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_ProductRecycleNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_ProductRecycleNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_ProductRecycleMaterialDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_ProductRecycleMaterialDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_ProductRecycleMaterialDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "ProductItem_Desc1", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "ProductItem_Desc2", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_ProductReceiptRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_ProductReceiptRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_ProductReceiptRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "ItemCode", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_ProductionReturnRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_ProductionReturnRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_ProductionReturnRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_ProductionPlanDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_ProductionPlanDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_ProductionPlanDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ProductionPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ProductionPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_PreparationPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_PreparationPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_PreparationPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_OfflineSettlementNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_OfflineSettlementNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_OfflineSettlementNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_NoOkConvertOkNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_NoOkConvertOkNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_NoOkConvertOkNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_MaterialRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_MaterialRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_JisProductReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_JisProductReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_JisProductReceiptNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_JisDeliverNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_JisDeliverNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_JisDeliverNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItemCode", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "FromBatch_ArriveDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromBatch_ExpireDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromBatch_ProduceDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToBatch_ArriveDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToBatch_ExpireDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToBatch_ProduceDate", - table: "Store_ItemTransformRequestDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToItem_Desc1", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToItem_Desc2", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToItemCode", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "FromBatch_ArriveDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromBatch_ExpireDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "FromBatch_ProduceDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToBatch_ArriveDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToBatch_ExpireDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToBatch_ProduceDate", - table: "Store_ItemTransformNoteDetail", - type: "datetime2", - nullable: true); - - migrationBuilder.AddColumn( - name: "ToItem_Desc1", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "ToItem_Desc2", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_IssueNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_IssueNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_IsolationNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_IsolationNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_IsolationNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_IsolationNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_IsolationNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Reason", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_InventoryTransferNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_InventoryTransferNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_InventoryTransferNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_InventoryInitialNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_InventoryInitialNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_InventoryInitialNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_InspectRequestSummaryDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_InspectRequestSummaryDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_InspectRequestSummaryDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_InspectRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_InspectRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_InspectRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_InspectRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_InspectRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_InspectNoteSummaryDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_InspectNoteSummaryDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_InspectNoteSummaryDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_InspectNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_InspectNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_InspectNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_InspectNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_InspectNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_InspectAbnormalNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_InspectAbnormalNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_InspectAbnormalNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_DeliverRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_DeliverRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_DeliverRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_DeliverPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_DeliverPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_DeliverPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_DeliverNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_DeliverNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToLocationGroup", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ToLocationArea", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationGroup", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromLocationArea", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_CustomerReturnNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_CustomerReturnNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_CustomerReturnNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_CustomerAsnDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_CustomerAsnDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_CustomerAsnDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_CountPlanDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_CountPlanDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_CountPlanDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_CountPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_CountPlanDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_CountNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_CountNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_CountNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_CountNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_CountNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_CountAdjustRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_CountAdjustRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_CountAdjustRequestDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "LocationGroup", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "LocationArea", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_CountAdjustNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_CountAdjustNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_CountAdjustNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_ContainerBindNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_ContainerBindNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_ContainerBindNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "PackingCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Lot", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ItemCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ContainerCode", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_BackFlushNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_BackFlushNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_BackFlushNoteDetail", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Uom", - table: "Store_BackFlushNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Batch_ProduceDate", - table: "Store_BackFlushNote", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ExpireDate", - table: "Store_BackFlushNote", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "Batch_ArriveDate", - table: "Store_BackFlushNote", - type: "datetime2", - nullable: true, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AddColumn( - name: "Item_Desc1", - table: "Store_BackFlushNote", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.AddColumn( - name: "Item_Desc2", - table: "Store_BackFlushNote", - type: "nvarchar(1024)", - maxLength: 1024, - nullable: true); - - migrationBuilder.CreateIndex( - name: "IX_Store_BackFlushNoteDetail_Number_ItemCode_Lot", - table: "Store_BackFlushNoteDetail", - columns: new[] { "Number", "ItemCode", "Lot" }, - unique: true, - filter: "[ItemCode] IS NOT NULL AND [Lot] IS NOT NULL"); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230208083909_MergeJobIntoStore.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230208083909_MergeJobIntoStore.Designer.cs deleted file mode 100644 index e4221d607..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230208083909_MergeJobIntoStore.Designer.cs +++ /dev/null @@ -1,19395 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230208083909_MergeJobIntoStore")] - partial class MergeJobIntoStore - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.12") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_CheckJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Order") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_CheckJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .HasColumnType("int"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .HasColumnType("int"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountStage") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_CountJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CountTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_CountJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RequestType") - .HasColumnType("int"); - - b.Property("Stage") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_DeliverJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasColumnType("nvarchar(max)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_DeliverJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .HasColumnType("int"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .HasColumnType("int"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_InspectJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_InspectJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_InspectJobSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .HasColumnType("int"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .HasColumnType("int"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .HasColumnType("int"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaterialRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_IssueJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliveryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("DistributionType") - .HasColumnType("int"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Operation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanBeginTime") - .HasColumnType("datetime2"); - - b.Property("PlannedSplitRule") - .HasColumnType("int"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RoundedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruncType") - .HasColumnType("int"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_IssueJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromArriveDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromProduceDate") - .HasColumnType("datetime2"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToArriveDate") - .HasColumnType("datetime2"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToExpireDate") - .HasColumnType("datetime2"); - - b.Property("ToItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToProduceDate") - .HasColumnType("datetime2"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromArriveDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromProduceDate") - .HasColumnType("datetime2"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToArriveDate") - .HasColumnType("datetime2"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToExpireDate") - .HasColumnType("datetime2"); - - b.Property("ToItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToProduceDate") - .HasColumnType("datetime2"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerAddressCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerWarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_JisDeliverJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerDesc") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerName") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_JisDeliverJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_ProductionReturnJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_ProductionReturnJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(1); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromLocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .HasColumnType("int"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_ProductReceiveJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_ProductReceiveJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .HasColumnType("int"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PurchaseReceiptJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PurchaseReceiptJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptInspectStatus") - .HasColumnType("int"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PurchaseReturnJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PurchaseReturnJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(2); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PutawayJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PutawayJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .HasColumnType("int"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .HasColumnType("int"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreateType") - .HasColumnType("int"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_UnplannedIssueJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_UnplannedIssueJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .HasColumnType("int"); - - b.Property("JobType") - .HasColumnType("int"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_UnplannedReceiptJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_UnplannedReceiptJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .HasColumnType("int"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .HasColumnType("int"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasColumnType("int"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WoStatus") - .HasColumnType("int"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CheckJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectJob", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJob", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230208083909_MergeJobIntoStore.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230208083909_MergeJobIntoStore.cs deleted file mode 100644 index 2fadde96a..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230208083909_MergeJobIntoStore.cs +++ /dev/null @@ -1,1613 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations; - -public partial class MergeJobIntoStore : Migration -{ - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.CreateTable( - name: "Job_CheckJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - DeliverNoteNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_CheckJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_CountJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CountPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CountStage = table.Column(type: "int", nullable: false), - CountMethod = table.Column(type: "int", nullable: false), - Type = table.Column(type: "int", nullable: false), - Description = table.Column(type: "nvarchar(max)", nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_CountJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_DeliverJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - DeliverRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - CustomerAddressCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DeliverTime = table.Column(type: "datetime2", nullable: false), - DeliverPlanNumber = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_DeliverJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_InspectJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - InspectNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(max)", nullable: true), - NextAction = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_InspectJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_IssueJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RequestType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - MaterialRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - UseOnTheWayLocation = table.Column(type: "bit", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_IssueJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_JisDeliverJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Customer = table.Column(type: "nvarchar(max)", nullable: true), - CustomerAddressCode = table.Column(type: "nvarchar(max)", nullable: true), - CustomerLocationCode = table.Column(type: "nvarchar(max)", nullable: true), - CustomerWarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), - ProjectCode = table.Column(type: "nvarchar(max)", nullable: true), - Position = table.Column(type: "nvarchar(max)", nullable: true), - PlanTime = table.Column(type: "datetime2", nullable: false), - ContainerQty = table.Column(type: "decimal(18,6)", nullable: false), - ItemQty = table.Column(type: "decimal(18,6)", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_JisDeliverJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_ProductionReturnJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ProductionReturnRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_ProductionReturnJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_ProductReceiveJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ProductionPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_ProductReceiveJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_PurchaseReceiptJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Type = table.Column(type: "int", nullable: false), - TimeWindow = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PlanArriveDate = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_PurchaseReceiptJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_PurchaseReturnJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PurchaseReturnRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReturnReason = table.Column(type: "nvarchar(max)", nullable: true), - ReturnTime = table.Column(type: "datetime2", nullable: false), - ReturnType = table.Column(type: "int", nullable: false, defaultValue: 2), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_PurchaseReturnJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_PutawayJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PutawayMode = table.Column(type: "int", nullable: false), - SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - InspectNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProductReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Type = table.Column(type: "int", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_PutawayJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_UnplannedIssueJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - UnplannedIssueRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - BuildDate = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_UnplannedIssueJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_UnplannedReceiptJob", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - UnplannedReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - BuildDate = table.Column(type: "datetime2", nullable: false), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - Worker = table.Column(type: "nvarchar(max)", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), - JobType = table.Column(type: "int", nullable: false), - JobStatus = table.Column(type: "int", nullable: false), - Priority = table.Column(type: "int", nullable: false, defaultValue: 0), - PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), - WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), - AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), - AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - AcceptTime = table.Column(type: "datetime2", nullable: true), - CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), - CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CompleteTime = table.Column(type: "datetime2", nullable: true), - WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_UnplannedReceiptJob", x => x.Id); - }); - - migrationBuilder.CreateTable( - name: "Job_CheckJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - Order = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CustomerItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ArriveDate = table.Column(type: "datetime2", nullable: false), - ProduceDate = table.Column(type: "datetime2", nullable: false), - ExpireDate = table.Column(type: "datetime2", nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_CheckJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_CheckJobDetail_Job_CheckJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_CheckJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_CountJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - CountLabel = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - InventoryQty = table.Column(type: "decimal(18,6)", nullable: false), - Uom = table.Column(type: "nvarchar(max)", nullable: true), - InventoryLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CountQty = table.Column(type: "decimal(18,6)", nullable: false), - CountTime = table.Column(type: "datetime2", nullable: true), - CountOperator = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CountDescription = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ArriveDate = table.Column(type: "datetime2", nullable: false), - ProduceDate = table.Column(type: "datetime2", nullable: false), - ExpireDate = table.Column(type: "datetime2", nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_CountJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_CountJobDetail_Job_CountJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_CountJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_DeliverJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationArea = table.Column(type: "nvarchar(max)", nullable: true), - ToLocationGroup = table.Column(type: "nvarchar(max)", nullable: true), - ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - OnTheWayLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendArriveDate = table.Column(type: "datetime2", nullable: false), - RecommendProduceDate = table.Column(type: "datetime2", nullable: false), - RecommendExpireDate = table.Column(type: "datetime2", nullable: false), - RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Uom = table.Column(type: "nvarchar(max)", nullable: true), - RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), - HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledArriveDate = table.Column(type: "datetime2", nullable: false), - HandledProduceDate = table.Column(type: "datetime2", nullable: false), - HandledExpireDate = table.Column(type: "datetime2", nullable: false), - HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledQty = table.Column(type: "decimal(18,6)", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_DeliverJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_DeliverJobDetail_Job_DeliverJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_DeliverJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_InspectJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - InspectType = table.Column(type: "int", nullable: false), - SamplePercent = table.Column(type: "decimal(18,6)", nullable: false), - Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReceiveQty = table.Column(type: "decimal(18,6)", nullable: false), - InspectQty = table.Column(type: "decimal(18,6)", nullable: false), - GoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - FailedReason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FailedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - CrackQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - InspectUser = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - NotPassedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - AbcClass = table.Column(type: "nvarchar(max)", nullable: true), - DetailInspectStatus = table.Column(type: "int", nullable: false), - Appearance = table.Column(type: "nvarchar(max)", nullable: true), - Volume = table.Column(type: "nvarchar(max)", nullable: true), - Weight = table.Column(type: "nvarchar(max)", nullable: true), - OtherPropertyJson = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ArriveDate = table.Column(type: "datetime2", nullable: false), - ProduceDate = table.Column(type: "datetime2", nullable: false), - ExpireDate = table.Column(type: "datetime2", nullable: false), - LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_InspectJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_InspectJobDetail_Job_InspectJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_InspectJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_InspectJobSummaryDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - InspectType = table.Column(type: "int", nullable: false), - SamplePercent = table.Column(type: "decimal(18,6)", nullable: false), - Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ReceiveQty = table.Column(type: "decimal(18,6)", nullable: false), - InspectQty = table.Column(type: "decimal(18,6)", nullable: false), - GoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - FailedReason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FailedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - CrackQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - InspectUser = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - NotPassedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), - SummaryInspectStatus = table.Column(type: "int", nullable: false), - AbcClass = table.Column(type: "nvarchar(max)", nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ArriveDate = table.Column(type: "datetime2", nullable: false), - ProduceDate = table.Column(type: "datetime2", nullable: false), - ExpireDate = table.Column(type: "datetime2", nullable: false), - InspectReport = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_InspectJobSummaryDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_InspectJobSummaryDetail_Job_InspectJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_InspectJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_IssueJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - RequestLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - OnTheWayLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - WorkStation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ExpiredTime = table.Column(type: "datetime2", nullable: false), - Operation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - DistributionType = table.Column(type: "int", nullable: false), - TruncType = table.Column(type: "int", nullable: false), - RoundedQty = table.Column(type: "decimal(18,6)", nullable: false), - PlannedSplitRule = table.Column(type: "int", nullable: false), - PlanBeginTime = table.Column(type: "datetime2", nullable: false), - DeliveryQty = table.Column(type: "decimal(18,6)", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendArriveDate = table.Column(type: "datetime2", nullable: false), - RecommendProduceDate = table.Column(type: "datetime2", nullable: false), - RecommendExpireDate = table.Column(type: "datetime2", nullable: false), - RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Uom = table.Column(type: "nvarchar(max)", nullable: true), - RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), - HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledArriveDate = table.Column(type: "datetime2", nullable: false), - HandledProduceDate = table.Column(type: "datetime2", nullable: false), - HandledExpireDate = table.Column(type: "datetime2", nullable: false), - HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledQty = table.Column(type: "decimal(18,6)", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_IssueJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_IssueJobDetail_Job_IssueJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_IssueJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_JisDeliverJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ContainerCode = table.Column(type: "nvarchar(max)", nullable: true), - ContainerName = table.Column(type: "nvarchar(max)", nullable: true), - ContainerDesc = table.Column(type: "nvarchar(max)", nullable: true), - ItemQty = table.Column(type: "decimal(18,6)", nullable: false), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Status = table.Column(type: "int", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(max)", nullable: true), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_JisDeliverJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_JisDeliverJobDetail_Job_JisDeliverJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_JisDeliverJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_ProductionReturnJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendArriveDate = table.Column(type: "datetime2", nullable: false), - RecommendProduceDate = table.Column(type: "datetime2", nullable: false), - RecommendExpireDate = table.Column(type: "datetime2", nullable: false), - RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Uom = table.Column(type: "nvarchar(max)", nullable: true), - RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), - HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledArriveDate = table.Column(type: "datetime2", nullable: false), - HandledProduceDate = table.Column(type: "datetime2", nullable: false), - HandledExpireDate = table.Column(type: "datetime2", nullable: false), - HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledQty = table.Column(type: "decimal(18,6)", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_ProductionReturnJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_ProductionReturnJobDetail_Job_ProductionReturnJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_ProductionReturnJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_ProductReceiveJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - RawLocationCode = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendArriveDate = table.Column(type: "datetime2", nullable: false), - RecommendProduceDate = table.Column(type: "datetime2", nullable: false), - RecommendExpireDate = table.Column(type: "datetime2", nullable: false), - RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Uom = table.Column(type: "nvarchar(max)", nullable: true), - RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), - HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledArriveDate = table.Column(type: "datetime2", nullable: false), - HandledProduceDate = table.Column(type: "datetime2", nullable: false), - HandledExpireDate = table.Column(type: "datetime2", nullable: false), - HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledQty = table.Column(type: "decimal(18,6)", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_ProductReceiveJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_ProductReceiveJobDetail_Job_ProductReceiveJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_ProductReceiveJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_PurchaseReceiptJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ArriveDate = table.Column(type: "datetime2", nullable: false), - PurchaseReceiptInspectStatus = table.Column(type: "int", nullable: false), - InspectPhotoJson = table.Column(type: "nvarchar(max)", nullable: true), - FailedReason = table.Column(type: "nvarchar(max)", nullable: true), - MassDefect = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPackUom = table.Column(type: "nvarchar(max)", nullable: true), - SupplierPackQty = table.Column(type: "decimal(18,6)", nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendArriveDate = table.Column(type: "datetime2", nullable: false), - RecommendProduceDate = table.Column(type: "datetime2", nullable: false), - RecommendExpireDate = table.Column(type: "datetime2", nullable: false), - RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Uom = table.Column(type: "nvarchar(max)", nullable: true), - RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), - HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledArriveDate = table.Column(type: "datetime2", nullable: false), - HandledProduceDate = table.Column(type: "datetime2", nullable: false), - HandledExpireDate = table.Column(type: "datetime2", nullable: false), - HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledQty = table.Column(type: "decimal(18,6)", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_PurchaseReceiptJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_PurchaseReceiptJobDetail_Job_PurchaseReceiptJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_PurchaseReceiptJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_PurchaseReturnJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Reason = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendArriveDate = table.Column(type: "datetime2", nullable: false), - RecommendProduceDate = table.Column(type: "datetime2", nullable: false), - RecommendExpireDate = table.Column(type: "datetime2", nullable: false), - RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Uom = table.Column(type: "nvarchar(max)", nullable: true), - RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), - HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledArriveDate = table.Column(type: "datetime2", nullable: false), - HandledProduceDate = table.Column(type: "datetime2", nullable: false), - HandledExpireDate = table.Column(type: "datetime2", nullable: false), - HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledQty = table.Column(type: "decimal(18,6)", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_PurchaseReturnJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_PurchaseReturnJobDetail_Job_PurchaseReturnJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_PurchaseReturnJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_PutawayJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendArriveDate = table.Column(type: "datetime2", nullable: false), - RecommendProduceDate = table.Column(type: "datetime2", nullable: false), - RecommendExpireDate = table.Column(type: "datetime2", nullable: false), - RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), - HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledArriveDate = table.Column(type: "datetime2", nullable: false), - HandledProduceDate = table.Column(type: "datetime2", nullable: false), - HandledExpireDate = table.Column(type: "datetime2", nullable: false), - HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledQty = table.Column(type: "decimal(18,6)", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_PutawayJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_PutawayJobDetail_Job_PutawayJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_PutawayJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_UnplannedIssueJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendArriveDate = table.Column(type: "datetime2", nullable: false), - RecommendProduceDate = table.Column(type: "datetime2", nullable: false), - RecommendExpireDate = table.Column(type: "datetime2", nullable: false), - RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Uom = table.Column(type: "nvarchar(max)", nullable: true), - RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), - HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledArriveDate = table.Column(type: "datetime2", nullable: false), - HandledProduceDate = table.Column(type: "datetime2", nullable: false), - HandledExpireDate = table.Column(type: "datetime2", nullable: false), - HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledQty = table.Column(type: "decimal(18,6)", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_UnplannedIssueJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_UnplannedIssueJobDetail_Job_UnplannedIssueJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_UnplannedIssueJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateTable( - name: "Job_UnplannedReceiptJobDetail", - columns: table => new - { - Id = table.Column(type: "uniqueidentifier", nullable: false), - ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), - ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), - CreationTime = table.Column(type: "datetime2", nullable: false), - CreatorId = table.Column(type: "uniqueidentifier", nullable: true), - LastModificationTime = table.Column(type: "datetime2", nullable: true), - LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), - MasterID = table.Column(type: "uniqueidentifier", nullable: false), - TenantId = table.Column(type: "uniqueidentifier", nullable: true), - Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - Remark = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), - ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), - StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), - Status = table.Column(type: "int", nullable: false), - RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendArriveDate = table.Column(type: "datetime2", nullable: false), - RecommendProduceDate = table.Column(type: "datetime2", nullable: false), - RecommendExpireDate = table.Column(type: "datetime2", nullable: false), - RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - RecommendWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - Uom = table.Column(type: "nvarchar(max)", nullable: true), - RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), - HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledArriveDate = table.Column(type: "datetime2", nullable: false), - HandledProduceDate = table.Column(type: "datetime2", nullable: false), - HandledExpireDate = table.Column(type: "datetime2", nullable: false), - HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), - HandledQty = table.Column(type: "decimal(18,6)", nullable: false) - }, - constraints: table => - { - table.PrimaryKey("PK_Job_UnplannedReceiptJobDetail", x => x.Id); - table.ForeignKey( - name: "FK_Job_UnplannedReceiptJobDetail_Job_UnplannedReceiptJob_MasterID", - column: x => x.MasterID, - principalTable: "Job_UnplannedReceiptJob", - principalColumn: "Id", - onDelete: ReferentialAction.Cascade); - }); - - migrationBuilder.CreateIndex( - name: "IX_Job_CheckJob_Number", - table: "Job_CheckJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_CheckJobDetail_MasterID", - table: "Job_CheckJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_CountJob_Number", - table: "Job_CountJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_CountJobDetail_MasterID", - table: "Job_CountJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_DeliverJob_Number", - table: "Job_DeliverJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_DeliverJobDetail_MasterID", - table: "Job_DeliverJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_InspectJob_Number", - table: "Job_InspectJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_InspectJobDetail_MasterID", - table: "Job_InspectJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_InspectJobSummaryDetail_MasterID", - table: "Job_InspectJobSummaryDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_IssueJob_Number", - table: "Job_IssueJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_IssueJobDetail_MasterID", - table: "Job_IssueJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_JisDeliverJob_Number", - table: "Job_JisDeliverJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_JisDeliverJobDetail_MasterID", - table: "Job_JisDeliverJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_ProductionReturnJob_Number", - table: "Job_ProductionReturnJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_ProductionReturnJobDetail_MasterID", - table: "Job_ProductionReturnJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_ProductReceiveJob_Number", - table: "Job_ProductReceiveJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_ProductReceiveJobDetail_MasterID", - table: "Job_ProductReceiveJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_PurchaseReceiptJob_Number", - table: "Job_PurchaseReceiptJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_PurchaseReceiptJobDetail_MasterID", - table: "Job_PurchaseReceiptJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_PurchaseReturnJob_Number", - table: "Job_PurchaseReturnJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_PurchaseReturnJobDetail_MasterID", - table: "Job_PurchaseReturnJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_PutawayJob_Number", - table: "Job_PutawayJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_PutawayJobDetail_MasterID", - table: "Job_PutawayJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_UnplannedIssueJob_Number", - table: "Job_UnplannedIssueJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_UnplannedIssueJobDetail_MasterID", - table: "Job_UnplannedIssueJobDetail", - column: "MasterID"); - - migrationBuilder.CreateIndex( - name: "IX_Job_UnplannedReceiptJob_Number", - table: "Job_UnplannedReceiptJob", - column: "Number", - unique: true); - - migrationBuilder.CreateIndex( - name: "IX_Job_UnplannedReceiptJobDetail_MasterID", - table: "Job_UnplannedReceiptJobDetail", - column: "MasterID"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropTable( - name: "Job_CheckJobDetail"); - - migrationBuilder.DropTable( - name: "Job_CountJobDetail"); - - migrationBuilder.DropTable( - name: "Job_DeliverJobDetail"); - - migrationBuilder.DropTable( - name: "Job_InspectJobDetail"); - - migrationBuilder.DropTable( - name: "Job_InspectJobSummaryDetail"); - - migrationBuilder.DropTable( - name: "Job_IssueJobDetail"); - - migrationBuilder.DropTable( - name: "Job_JisDeliverJobDetail"); - - migrationBuilder.DropTable( - name: "Job_ProductionReturnJobDetail"); - - migrationBuilder.DropTable( - name: "Job_ProductReceiveJobDetail"); - - migrationBuilder.DropTable( - name: "Job_PurchaseReceiptJobDetail"); - - migrationBuilder.DropTable( - name: "Job_PurchaseReturnJobDetail"); - - migrationBuilder.DropTable( - name: "Job_PutawayJobDetail"); - - migrationBuilder.DropTable( - name: "Job_UnplannedIssueJobDetail"); - - migrationBuilder.DropTable( - name: "Job_UnplannedReceiptJobDetail"); - - migrationBuilder.DropTable( - name: "Job_CheckJob"); - - migrationBuilder.DropTable( - name: "Job_CountJob"); - - migrationBuilder.DropTable( - name: "Job_DeliverJob"); - - migrationBuilder.DropTable( - name: "Job_InspectJob"); - - migrationBuilder.DropTable( - name: "Job_IssueJob"); - - migrationBuilder.DropTable( - name: "Job_JisDeliverJob"); - - migrationBuilder.DropTable( - name: "Job_ProductionReturnJob"); - - migrationBuilder.DropTable( - name: "Job_ProductReceiveJob"); - - migrationBuilder.DropTable( - name: "Job_PurchaseReceiptJob"); - - migrationBuilder.DropTable( - name: "Job_PurchaseReturnJob"); - - migrationBuilder.DropTable( - name: "Job_PutawayJob"); - - migrationBuilder.DropTable( - name: "Job_UnplannedIssueJob"); - - migrationBuilder.DropTable( - name: "Job_UnplannedReceiptJob"); - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215014905_StoreEnumToString.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215014905_StoreEnumToString.Designer.cs deleted file mode 100644 index b67a694f8..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215014905_StoreEnumToString.Designer.cs +++ /dev/null @@ -1,19749 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230215014905_StoreEnumToString")] - partial class StoreEnumToString - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.13") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_CheckJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Order") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_CheckJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountStage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_CountJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CountTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_CountJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Stage") - .IsRequired() - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasDefaultValue("First"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_DeliverJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasColumnType("nvarchar(max)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_DeliverJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_InspectJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_InspectJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_InspectJobSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaterialRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_IssueJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliveryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("DistributionType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Operation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanBeginTime") - .HasColumnType("datetime2"); - - b.Property("PlannedSplitRule") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RoundedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruncType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_IssueJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromArriveDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromProduceDate") - .HasColumnType("datetime2"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToArriveDate") - .HasColumnType("datetime2"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToExpireDate") - .HasColumnType("datetime2"); - - b.Property("ToItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToProduceDate") - .HasColumnType("datetime2"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromArriveDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromProduceDate") - .HasColumnType("datetime2"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToArriveDate") - .HasColumnType("datetime2"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToExpireDate") - .HasColumnType("datetime2"); - - b.Property("ToItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToProduceDate") - .HasColumnType("datetime2"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerAddressCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerWarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_JisDeliverJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerDesc") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerName") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_JisDeliverJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasDefaultValue("New"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_ProductionReturnJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_ProductionReturnJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasDefaultValue("New"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromLocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_ProductReceiveJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_ProductReceiveJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PurchaseReceiptJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PurchaseReceiptJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .IsRequired() - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasDefaultValue("AfterPuton"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PurchaseReturnJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PurchaseReturnJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .IsRequired() - .ValueGeneratedOnAdd() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasDefaultValue("AfterPuton"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutawayMode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PutawayJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PutawayJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreateType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_UnplannedIssueJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_UnplannedIssueJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_UnplannedReceiptJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_UnplannedReceiptJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WoStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CheckJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectJob", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJob", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215014905_StoreEnumToString.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215014905_StoreEnumToString.cs deleted file mode 100644 index b02dbbc35..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215014905_StoreEnumToString.cs +++ /dev/null @@ -1,3221 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - public partial class StoreEnumToString : Migration - { - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.AlterColumn( - name: "WoStatus", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_WorkOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_UnplannedReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_UnplannedIssueRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_TransferRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_TransferRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_TransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_SupplierAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "CreateType", - table: "Store_SupplierAsn", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ScrapRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "LineStatus", - table: "Store_SaleOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "SoStatus", - table: "Store_SaleOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_PutawayRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_PutawayRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_PutawayRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "PutawayMode", - table: "Store_PutawayRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_PutawayNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ReturnType", - table: "Store_PurchaseReturnRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_PurchaseReturnRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PurchaseReturnNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ReturnType", - table: "Store_PurchaseReturnNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "AfterPuton", - oldClrType: typeof(int), - oldType: "int", - oldDefaultValue: 2); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_PurchaseReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "PurchaseReceiptInspectStatus", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_PurchaseReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PurchaseReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "LineStatus", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "OrderStatus", - table: "Store_PurchaseOrder", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ProductRecycleRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ProductReceiptRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ReceiptType", - table: "Store_ProductReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ProductionReturnRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "New", - oldClrType: typeof(int), - oldType: "int", - oldDefaultValue: 1); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ProductionPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "LineStatus", - table: "Store_PreparationPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PreparationPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_MaterialRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_MaterialRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "New", - oldClrType: typeof(int), - oldType: "int", - oldDefaultValue: 1); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ReceiptType", - table: "Store_JisProductReceiptNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ItemTransformRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_IsolationNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "TransferType", - table: "Store_InventoryTransferNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "SummaryInspectStatus", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "DetailInspectStatus", - table: "Store_InspectRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_InspectRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "SummaryInspectStatus", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "DetailInspectStatus", - table: "Store_InspectNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "NextAction", - table: "Store_InspectNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ExchangeData", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ErrorCode", - table: "Store_ExchangeData", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "DataAction", - table: "Store_ExchangeData", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_DeliverRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "DeliverRequestType", - table: "Store_DeliverRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_DeliverPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "DeliverRequestType", - table: "Store_DeliverNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Stage", - table: "Store_CountPlanDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_CountPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Stage", - table: "Store_CountPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "First", - oldClrType: typeof(int), - oldType: "int", - oldDefaultValue: 1); - - migrationBuilder.AlterColumn( - name: "RequestType", - table: "Store_CountPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_CountPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "CountMethod", - table: "Store_CountPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Stage", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "DetailStatus", - table: "Store_CountNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_CountNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Stage", - table: "Store_CountNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_CountAdjustRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "TransInOut", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "BindType", - table: "Store_ContainerBindNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_UnplannedReceiptJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_UnplannedReceiptJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_UnplannedReceiptJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_UnplannedIssueJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_UnplannedIssueJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_UnplannedIssueJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_PutawayJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Job_PutawayJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "PutawayMode", - table: "Job_PutawayJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_PutawayJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_PutawayJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_PurchaseReturnJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "ReturnType", - table: "Job_PurchaseReturnJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "AfterPuton", - oldClrType: typeof(int), - oldType: "int", - oldDefaultValue: 2); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_PurchaseReturnJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_PurchaseReturnJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_PurchaseReceiptJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "PurchaseReceiptInspectStatus", - table: "Job_PurchaseReceiptJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Job_PurchaseReceiptJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_PurchaseReceiptJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_PurchaseReceiptJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_ProductReceiveJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_ProductReceiveJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_ProductReceiveJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_ProductionReturnJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_ProductionReturnJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_ProductionReturnJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_JisDeliverJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_JisDeliverJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "TruncType", - table: "Job_IssueJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_IssueJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "PlannedSplitRule", - table: "Job_IssueJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "DistributionType", - table: "Job_IssueJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_IssueJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_IssueJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "SummaryInspectStatus", - table: "Job_InspectJobSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Job_InspectJobSummaryDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_InspectJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Job_InspectJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "DetailInspectStatus", - table: "Job_InspectJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "NextAction", - table: "Job_InspectJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_InspectJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_InspectJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_DeliverJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_DeliverJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_DeliverJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_CountJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Job_CountJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_CountJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_CountJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "CountStage", - table: "Job_CountJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "CountMethod", - table: "Job_CountJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_CheckJobDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_CheckJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_CheckJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.AlterColumn( - name: "WoStatus", - table: "Store_WorkOrder", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_WorkOrder", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_WarehouseTransferNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_WarehouseTransferNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_UnplannedReceiptRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_UnplannedReceiptRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_UnplannedReceiptNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_UnplannedIssueRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_UnplannedIssueRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_UnplannedIssueNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_TransferRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_TransferRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_TransferRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_TransferNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_TransferNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_SupplierAsn", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "CreateType", - table: "Store_SupplierAsn", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ScrapRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_ScrapNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_ScrapNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LineStatus", - table: "Store_SaleOrderDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "SoStatus", - table: "Store_SaleOrder", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ReceiptAbnormalNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_PutawayRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_PutawayRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_PutawayRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_PutawayRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "PutawayMode", - table: "Store_PutawayRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_PutawayNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_PutawayNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_PutawayNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PurchaseReturnRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ReturnType", - table: "Store_PurchaseReturnRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_PurchaseReturnRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PurchaseReturnNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PurchaseReturnNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ReturnType", - table: "Store_PurchaseReturnNote", - type: "int", - nullable: false, - defaultValue: 2, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "AfterPuton"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_PurchaseReceiptRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PurchaseReceiptNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "PurchaseReceiptInspectStatus", - table: "Store_PurchaseReceiptNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_PurchaseReceiptNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PurchaseReceiptNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LineStatus", - table: "Store_PurchaseOrderDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "OrderStatus", - table: "Store_PurchaseOrder", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ProductRecycleRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ProductRecycleRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ProductRecycleNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ProductRecycleMaterialDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ProductReceiptRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ProductReceiptNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ReceiptType", - table: "Store_ProductReceiptNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_ProductionReturnRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_ProductionReturnRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ProductionReturnRequest", - type: "int", - nullable: false, - defaultValue: 1, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "New"); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_ProductionReturnNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_ProductionReturnNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ProductionPlan", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "LineStatus", - table: "Store_PreparationPlanDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_PreparationPlan", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_OfflineSettlementNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_NoOkConvertOkNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_NoOkConvertOkNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_MaterialRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_MaterialRequest", - type: "int", - nullable: false, - defaultValue: 1, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "New"); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_JisProductReceiptNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ReceiptType", - table: "Store_JisProductReceiptNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_JisDeliverNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_JisDeliverNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_ItemTransformRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_ItemTransformRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ItemTransformRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_ItemTransformNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_ItemTransformNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_IssueNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_IssueNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_IsolationNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_IsolationNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_InventoryTransferNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_InventoryTransferNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "TransferType", - table: "Store_InventoryTransferNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_InventoryInitialNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "SummaryInspectStatus", - table: "Store_InspectRequestSummaryDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Store_InspectRequestSummaryDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_InspectRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Store_InspectRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "DetailInspectStatus", - table: "Store_InspectRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_InspectRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "SummaryInspectStatus", - table: "Store_InspectNoteSummaryDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Store_InspectNoteSummaryDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_InspectNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Store_InspectNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "DetailInspectStatus", - table: "Store_InspectNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "NextAction", - table: "Store_InspectNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_ExchangeData", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ErrorCode", - table: "Store_ExchangeData", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "DataAction", - table: "Store_ExchangeData", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_DeliverRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "DeliverRequestType", - table: "Store_DeliverRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_DeliverPlan", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_DeliverNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_DeliverNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "DeliverRequestType", - table: "Store_DeliverNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ToStatus", - table: "Store_CustomerReturnNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "FromStatus", - table: "Store_CustomerReturnNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_CountPlanDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Stage", - table: "Store_CountPlanDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_CountPlan", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Stage", - table: "Store_CountPlan", - type: "int", - nullable: false, - defaultValue: 1, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "First"); - - migrationBuilder.AlterColumn( - name: "RequestType", - table: "Store_CountPlan", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_CountPlan", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "CountMethod", - table: "Store_CountPlan", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_CountNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Stage", - table: "Store_CountNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "DetailStatus", - table: "Store_CountNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_CountNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Stage", - table: "Store_CountNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_CountAdjustRequestDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_CountAdjustRequest", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "TransInOut", - table: "Store_CountAdjustNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_CountAdjustNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "BindType", - table: "Store_ContainerBindNote", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Store_BackFlushNoteDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_UnplannedReceiptJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_UnplannedReceiptJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_UnplannedReceiptJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_UnplannedIssueJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_UnplannedIssueJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_UnplannedIssueJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_PutawayJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Job_PutawayJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "PutawayMode", - table: "Job_PutawayJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_PutawayJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_PutawayJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_PurchaseReturnJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ReturnType", - table: "Job_PurchaseReturnJob", - type: "int", - nullable: false, - defaultValue: 2, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "AfterPuton"); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_PurchaseReturnJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_PurchaseReturnJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_PurchaseReceiptJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "PurchaseReceiptInspectStatus", - table: "Job_PurchaseReceiptJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Job_PurchaseReceiptJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_PurchaseReceiptJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_PurchaseReceiptJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_ProductReceiveJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_ProductReceiveJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_ProductReceiveJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_ProductionReturnJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_ProductionReturnJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_ProductionReturnJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_JisDeliverJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_JisDeliverJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "TruncType", - table: "Job_IssueJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_IssueJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "PlannedSplitRule", - table: "Job_IssueJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "DistributionType", - table: "Job_IssueJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_IssueJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_IssueJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "SummaryInspectStatus", - table: "Job_InspectJobSummaryDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Job_InspectJobSummaryDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_InspectJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "InspectType", - table: "Job_InspectJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "DetailInspectStatus", - table: "Job_InspectJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "NextAction", - table: "Job_InspectJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_InspectJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_InspectJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_DeliverJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_DeliverJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_DeliverJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_CountJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Job_CountJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_CountJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_CountJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "CountStage", - table: "Job_CountJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "CountMethod", - table: "Job_CountJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_CheckJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobType", - table: "Job_CheckJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "JobStatus", - table: "Job_CheckJob", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215072221_StoreDbEnumToString.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215072221_StoreDbEnumToString.Designer.cs deleted file mode 100644 index 2128e44ac..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215072221_StoreDbEnumToString.Designer.cs +++ /dev/null @@ -1,19739 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230215072221_StoreDbEnumToString")] - partial class StoreDbEnumToString - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.13") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_CheckJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Order") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_CheckJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountStage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_CountJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CountTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_CountJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_DeliverJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasColumnType("nvarchar(max)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_DeliverJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2(7)"); - - b.Property("ErrorCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ErrorMessage") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .ValueGeneratedOnAdd() - .HasColumnType("bigint"); - - SqlServerPropertyBuilderExtensions.UseIdentityColumn(b.Property("Number"), 1L, 1); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_InspectJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_InspectJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_InspectJobSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaterialRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_IssueJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliveryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("DistributionType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Operation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanBeginTime") - .HasColumnType("datetime2"); - - b.Property("PlannedSplitRule") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RoundedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruncType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_IssueJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromArriveDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromProduceDate") - .HasColumnType("datetime2"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToArriveDate") - .HasColumnType("datetime2"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToExpireDate") - .HasColumnType("datetime2"); - - b.Property("ToItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToProduceDate") - .HasColumnType("datetime2"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromArriveDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromProduceDate") - .HasColumnType("datetime2"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToArriveDate") - .HasColumnType("datetime2"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToExpireDate") - .HasColumnType("datetime2"); - - b.Property("ToItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToProduceDate") - .HasColumnType("datetime2"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerAddressCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerWarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_JisDeliverJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerDesc") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerName") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_JisDeliverJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_ProductionReturnJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_ProductionReturnJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromLocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasColumnType("nvarchar(450)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("L7Part") - .HasColumnType("nvarchar(450)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(450)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(450)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_ProductReceiveJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_ProductReceiveJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PurchaseReceiptJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PurchaseReceiptJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PurchaseReturnJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PurchaseReturnJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutawayMode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PutawayJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PutawayJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreateType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_UnplannedIssueJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_UnplannedIssueJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_UnplannedReceiptJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_UnplannedReceiptJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WoStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(4096) - .HasColumnType("nvarchar(max)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CheckJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectJob", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJob", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215072221_StoreDbEnumToString.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215072221_StoreDbEnumToString.cs deleted file mode 100644 index cb48e3bb7..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230215072221_StoreDbEnumToString.cs +++ /dev/null @@ -1,125 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - public partial class StoreDbEnumToString : Migration - { - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.AlterColumn( - name: "ReturnType", - table: "Store_PurchaseReturnNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "AfterPuton"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ProductionReturnRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "New"); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_MaterialRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "New"); - - migrationBuilder.AlterColumn( - name: "Stage", - table: "Store_CountPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "First"); - - migrationBuilder.AlterColumn( - name: "ReturnType", - table: "Job_PurchaseReturnJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldDefaultValue: "AfterPuton"); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.AlterColumn( - name: "ReturnType", - table: "Store_PurchaseReturnNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "AfterPuton", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_ProductionReturnRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "New", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "RequestStatus", - table: "Store_MaterialRequest", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "New", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Stage", - table: "Store_CountPlan", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "First", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "ReturnType", - table: "Job_PurchaseReturnJob", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "AfterPuton", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230401163806_Added_AddPurchaseOrder.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230401163806_Added_AddPurchaseOrder.Designer.cs deleted file mode 100644 index a44e6e7c8..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230401163806_Added_AddPurchaseOrder.Designer.cs +++ /dev/null @@ -1,20949 +0,0 @@ -// -using System; -using Microsoft.EntityFrameworkCore; -using Microsoft.EntityFrameworkCore.Infrastructure; -using Microsoft.EntityFrameworkCore.Metadata; -using Microsoft.EntityFrameworkCore.Migrations; -using Microsoft.EntityFrameworkCore.Storage.ValueConversion; -using Volo.Abp.EntityFrameworkCore; -using Win_in.Sfs.Wms.Store.EntityFrameworkCore; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - [DbContext(typeof(StoreDbContext))] - [Migration("20230401163806_Added_AddPurchaseOrder")] - partial class Added_AddPurchaseOrder - { - protected override void BuildTargetModel(ModelBuilder modelBuilder) - { -#pragma warning disable 612, 618 - modelBuilder - .HasAnnotation("_Abp_DatabaseProvider", EfCoreDatabaseProvider.SqlServer) - .HasAnnotation("ProductVersion", "6.0.13") - .HasAnnotation("Relational:MaxIdentifierLength", 128); - - SqlServerModelBuilderExtensions.UseIdentityColumns(modelBuilder, 1L, 1); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductRecycleNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_BackFlushNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("IsOffLine") - .HasColumnType("bit"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_BackFlushNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_CheckJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Order") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_CheckJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BindTime") - .HasColumnType("datetime2"); - - b.Property("BindType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ContainerBindNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_ContainerBindNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountAdjustRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountNoteNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAdjusted") - .HasColumnType("bit"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AdjustQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransInOut") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountNoteNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountAdjustRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_CountAdjustRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountStage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_CountJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CountTime") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InventoryLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_CountJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("Adjusted") - .HasColumnType("bit"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CountPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CountMethod") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Description") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JsonInventoryStatus") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonItemCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("JsonLocationCodes") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CountPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("AuditCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AuditCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("AuditCountTime") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CountLabel") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailStatus") - .HasColumnType("int"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FinalCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FirstCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("FirstCountTime") - .HasColumnType("datetime2"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RepeatCountDescription") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountOperator") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RepeatCountQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("RepeatCountTime") - .HasColumnType("datetime2"); - - b.Property("Stage") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "CountLabel") - .IsUnique(); - - b.ToTable("Store_CountPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BeginTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DockCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EndTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_CustomerAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_CustomerReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_CustomerReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_DeliverJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationArea"); - - b.Property("HandledFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationCode"); - - b.Property("HandledFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationErpCode"); - - b.Property("HandledFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationGroup"); - - b.Property("HandledFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromWarehouseCode"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationArea"); - - b.Property("RecommendFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationCode"); - - b.Property("RecommendFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationErpCode"); - - b.Property("RecommendFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationGroup"); - - b.Property("RecommendFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromWarehouseCode"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasColumnType("nvarchar(max)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_DeliverJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("DeliverRequestType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationArea"); - - b.Property("HandledFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationCode"); - - b.Property("HandledFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationErpCode"); - - b.Property("HandledFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationGroup"); - - b.Property("HandledFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromWarehouseCode"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationArea"); - - b.Property("RecommendFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationCode"); - - b.Property("RecommendFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationErpCode"); - - b.Property("RecommendFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationGroup"); - - b.Property("RecommendFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromWarehouseCode"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_DeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Project") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoNumber", "SoLine") - .IsUnique() - .HasFilter("[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); - - b.ToTable("Store_DeliverPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerAddressCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverRequestType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_DeliverRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AreaCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_DeliverRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ExchangeData", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DataAction") - .HasColumnType("int"); - - b.Property("DataContent") - .HasColumnType("nvarchar(max)"); - - b.Property("DataIdentityCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DataType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DestinationSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ErrorCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ErrorMessage") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .HasColumnType("bigint"); - - b.Property("ReadTime") - .HasColumnType("datetime2"); - - b.Property("Reader") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RetryTimes") - .HasColumnType("int"); - - b.Property("SourceSystem") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WriteTime") - .HasColumnType("datetime2"); - - b.Property("Writer") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.ToTable("Store_ExchangeData", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_InspectJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_InspectJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_InspectJobSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("NextAction") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("Appearance") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OtherPropertyJson") - .HasColumnType("nvarchar(max)"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Volume") - .HasColumnType("nvarchar(max)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Weight") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("FailedReason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("InspectUser") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_InspectNoteSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InspectRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("Attributes") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DetailInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_InspectRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbcClass") - .HasColumnType("nvarchar(max)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CrackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("GoodQty") - .HasColumnType("decimal(18,6)"); - - b.Property("InspectQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("InspectReport") - .HasColumnType("nvarchar(max)"); - - b.Property("InspectType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NotPassedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ReceiveQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SamplePercent") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SummaryInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "Lot") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InspectRequestSummaryDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryInitialNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.Property("Id") - .ValueGeneratedOnAdd() - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_InventoryInitialNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TransferType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_InventoryTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_InventoryTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IsolationNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IsolationNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MaterialRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_IssueJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliveryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("DistributionType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationArea"); - - b.Property("HandledFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationCode"); - - b.Property("HandledFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationErpCode"); - - b.Property("HandledFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationGroup"); - - b.Property("HandledFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromWarehouseCode"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Operation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanBeginTime") - .HasColumnType("datetime2"); - - b.Property("PlannedSplitRule") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationArea"); - - b.Property("RecommendFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationCode"); - - b.Property("RecommendFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationErpCode"); - - b.Property("RecommendFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationGroup"); - - b.Property("RecommendFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromWarehouseCode"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RoundedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruncType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_IssueJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RequestType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_IssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationArea"); - - b.Property("HandledFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationCode"); - - b.Property("HandledFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationErpCode"); - - b.Property("HandledFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationGroup"); - - b.Property("HandledFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromWarehouseCode"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("IssueTime") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationArea"); - - b.Property("RecommendFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationCode"); - - b.Property("RecommendFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationErpCode"); - - b.Property("RecommendFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationGroup"); - - b.Property("RecommendFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromWarehouseCode"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("FromPackingCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_IssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConcurrencyStamp") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromArriveDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromProduceDate") - .HasColumnType("datetime2"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToArriveDate") - .HasColumnType("datetime2"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToExpireDate") - .HasColumnType("datetime2"); - - b.Property("ToItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToProduceDate") - .HasColumnType("datetime2"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ItemTransformRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromArriveDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromProduceDate") - .HasColumnType("datetime2"); - - b.Property("FromQty") - .HasColumnType("decimal(18,6)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToArriveDate") - .HasColumnType("datetime2"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToExpireDate") - .HasColumnType("datetime2"); - - b.Property("ToItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToProduceDate") - .HasColumnType("datetime2"); - - b.Property("ToQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ItemTransformRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerAddressCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CustomerWarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_JisDeliverJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerDesc") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerName") - .HasColumnType("nvarchar(max)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_JisDeliverJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ArrivalTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Customer") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CustomerAddressCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TotalPackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisDeliverNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeliverTime") - .HasColumnType("datetime2"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnlineType") - .HasColumnType("nvarchar(max)"); - - b.Property("PackCapacity") - .HasColumnType("nvarchar(max)"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Stage") - .HasColumnType("nvarchar(max)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("UsedFor") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_JisDeliverNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContainerQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemQty") - .HasColumnType("decimal(18,6)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SeqNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_JisProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PreparationPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_MaterialRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpiredTime") - .HasColumnType("datetime2"); - - b.Property("FromLocationArea") - .HasColumnType("nvarchar(max)"); - - b.Property("IssuedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceivedQty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationArea") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationGroup") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "ToLocationCode") - .IsUnique(); - - b.ToTable("Store_MaterialRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_NoOkConvertOkNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_NoOkConvertOkNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_OfflineSettlementNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PreparationPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LatestTime") - .HasColumnType("datetime2"); - - b.Property("LineStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WorkStation") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_PreparationPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("PlanTime") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Shift") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionPlan", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("GoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .HasColumnType("int"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("NoGoodQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductionPlanDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_ProductionReturnJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("HandledToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationArea"); - - b.Property("HandledToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationCode"); - - b.Property("HandledToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationErpCode"); - - b.Property("HandledToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationGroup"); - - b.Property("HandledToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("RecommendToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationArea"); - - b.Property("RecommendToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationCode"); - - b.Property("RecommendToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationErpCode"); - - b.Property("RecommendToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationGroup"); - - b.Property("RecommendToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToWarehouseCode"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_ProductionReturnJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductionReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("HandledToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationArea"); - - b.Property("HandledToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationCode"); - - b.Property("HandledToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationErpCode"); - - b.Property("HandledToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationGroup"); - - b.Property("HandledToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("RecommendToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationArea"); - - b.Property("RecommendToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationCode"); - - b.Property("RecommendToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationErpCode"); - - b.Property("RecommendToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationGroup"); - - b.Property("RecommendToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToWarehouseCode"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_ProductionReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("ItemCode"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromLocationCode") - .IsUnique(); - - b.ToTable("Store_ProductionReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("Configuration") - .HasColumnType("nvarchar(max)"); - - b.Property("ContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasColumnType("nvarchar(max)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("Status") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Year") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductL7PartsNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CanBuy") - .HasColumnType("bit"); - - b.Property("CanMake") - .HasColumnType("bit"); - - b.Property("Configuration") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreateDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FATA") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("L7Part") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Position") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductNo") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Program") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasColumnType("int"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RowID") - .HasColumnType("int"); - - b.Property("State") - .HasColumnType("int"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductNo", "Position", "Configuration", "L7Part") - .IsUnique() - .HasFilter("[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); - - b.ToTable("Store_ProductL7PartsNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SourceNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkShop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("HandledToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationArea"); - - b.Property("HandledToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationCode"); - - b.Property("HandledToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationErpCode"); - - b.Property("HandledToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationGroup"); - - b.Property("HandledToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("RecommendToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationArea"); - - b.Property("RecommendToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationCode"); - - b.Property("RecommendToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationErpCode"); - - b.Property("RecommendToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationGroup"); - - b.Property("RecommendToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToWarehouseCode"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_ProductReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanDate") - .HasColumnType("datetime2"); - - b.Property("ProdLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductionPlanNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Team") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("ReturnQty") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ProductReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductionPlanNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_ProductReceiveJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("HandledToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationArea"); - - b.Property("HandledToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationCode"); - - b.Property("HandledToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationErpCode"); - - b.Property("HandledToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationGroup"); - - b.Property("HandledToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProdLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("RecommendToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationArea"); - - b.Property("RecommendToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationCode"); - - b.Property("RecommendToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationErpCode"); - - b.Property("RecommendToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationGroup"); - - b.Property("RecommendToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToWarehouseCode"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_ProductReceiveJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProductItemCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProductPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ProductItemCode", "ItemCode"); - - b.ToTable("Store_ProductRecycleMaterialDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("RecycleTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Shift") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.Property("Workshop") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("BomVersion") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RawLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_ProductRecycleRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("OrderStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("IsConsignment") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Lot") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderRemark") - .HasColumnType("nvarchar(max)"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProjectCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutAwayQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceivedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("ReturnedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ShippedQty") - .HasColumnType("decimal(18,6)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("ItemCode", "Number", "PoLine") - .IsUnique() - .HasFilter("[PoLine] IS NOT NULL"); - - b.ToTable("Store_PurchaseOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PurchaseReceiptJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("HandledToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationArea"); - - b.Property("HandledToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationCode"); - - b.Property("HandledToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationErpCode"); - - b.Property("HandledToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationGroup"); - - b.Property("HandledToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToWarehouseCode"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("RecommendToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationArea"); - - b.Property("RecommendToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationCode"); - - b.Property("RecommendToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationErpCode"); - - b.Property("RecommendToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationGroup"); - - b.Property("RecommendToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToWarehouseCode"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PurchaseReceiptJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiveTime") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FailedReason") - .HasColumnType("nvarchar(max)"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("HandledToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationArea"); - - b.Property("HandledToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationCode"); - - b.Property("HandledToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationErpCode"); - - b.Property("HandledToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationGroup"); - - b.Property("HandledToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToWarehouseCode"); - - b.Property("InspectPhotoJson") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MassDefect") - .HasColumnType("nvarchar(max)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("PurchaseReceiptInspectStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("RecommendToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationArea"); - - b.Property("RecommendToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationCode"); - - b.Property("RecommendToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationErpCode"); - - b.Property("RecommendToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationGroup"); - - b.Property("RecommendToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToWarehouseCode"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PurchaseReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_PurchaseReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PurchaseReturnJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationArea"); - - b.Property("HandledFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationCode"); - - b.Property("HandledFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationErpCode"); - - b.Property("HandledFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationGroup"); - - b.Property("HandledFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromWarehouseCode"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationArea"); - - b.Property("RecommendFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationCode"); - - b.Property("RecommendFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationErpCode"); - - b.Property("RecommendFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationGroup"); - - b.Property("RecommendFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromWarehouseCode"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PurchaseReturnJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReturnRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("ReturnReason") - .HasColumnType("nvarchar(max)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationArea"); - - b.Property("HandledFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationCode"); - - b.Property("HandledFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationErpCode"); - - b.Property("HandledFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationGroup"); - - b.Property("HandledFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromWarehouseCode"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationArea"); - - b.Property("RecommendFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationCode"); - - b.Property("RecommendFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationErpCode"); - - b.Property("RecommendFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationGroup"); - - b.Property("RecommendFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromWarehouseCode"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReturnTime") - .HasColumnType("datetime2"); - - b.Property("ReturnType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_PurchaseReturnRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PutawayMode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_PutawayJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("HandledToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationArea"); - - b.Property("HandledToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationCode"); - - b.Property("HandledToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationErpCode"); - - b.Property("HandledToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationGroup"); - - b.Property("HandledToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("RecommendToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationArea"); - - b.Property("RecommendToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationCode"); - - b.Property("RecommendToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationErpCode"); - - b.Property("RecommendToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationGroup"); - - b.Property("RecommendToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToWarehouseCode"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_PutawayJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProductReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("HandledToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationArea"); - - b.Property("HandledToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationCode"); - - b.Property("HandledToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationErpCode"); - - b.Property("HandledToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationGroup"); - - b.Property("HandledToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("RecommendToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationArea"); - - b.Property("RecommendToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationCode"); - - b.Property("RecommendToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationErpCode"); - - b.Property("RecommendToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationGroup"); - - b.Property("RecommendToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToWarehouseCode"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); - - b.ToTable("Store_PutawayNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("InspectNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("ProductReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PurchaseReceiptRequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("PutawayMode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReceiptNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RpNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("SupplierCode") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_PutawayRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("InventoryQty") - .HasColumnType("decimal(18,6)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_PutawayRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AsnNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("SupplierCode"); - - b.HasIndex("AsnNumber", "Number", "SupplierCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AbnormalType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("Photos") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReceiptNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ReceiptNumber") - .IsUnique(); - - b.ToTable("Store_ReceiptAbnormalNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode") - .IsUnique(); - - b.ToTable("Store_RecycledMaterialReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OrderDate") - .HasColumnType("datetime2"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SoStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SoType") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TaxRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(0m); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Version") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("CustomerCode"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_SaleOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ConvertRate") - .ValueGeneratedOnAdd() - .HasColumnType("decimal(18,6)") - .HasDefaultValue(1m); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("CustomerPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("CustomerPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LineStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SoLine") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "SoLine", "ItemCode") - .IsUnique(); - - b.ToTable("Store_SaleOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("ScrapRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(450)"); - - b.Property("FromPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); - - b.ToTable("Store_ScrapNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_ScrapRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "LocationCode") - .IsUnique(); - - b.ToTable("Store_ScrapRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ContactEmail") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ContactPhone") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreateType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("DockCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DueDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PlanArriveDate") - .HasColumnType("datetime2"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RpNumber") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ShipDate") - .HasColumnType("datetime2"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("SupplierCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("TimeWindow") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TruckNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.HasIndex("SupplierCode"); - - b.ToTable("Store_SupplierAsn", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("ConvertRate") - .HasColumnType("decimal(18,6)"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("Ctype") - .HasColumnType("nvarchar(max)"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("PlanUserCode") - .HasColumnType("nvarchar(max)"); - - b.Property("PoLine") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoLine"); - - b.Property("PoNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PoNumber"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("ProjectCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("RecommendErpCode") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("SupplierPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierPackUom") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode", "PackingCode") - .IsUnique(); - - b.ToTable("Store_SupplierAsnDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("ConfirmTime") - .HasColumnType("datetime2"); - - b.Property("Confirmed") - .HasColumnType("bit"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestNumber") - .HasColumnType("nvarchar(max)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("OnTheWayLocationCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_TransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UseOnTheWayLocation") - .HasColumnType("bit"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_TransferRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasColumnType("nvarchar(max)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Store_TransferRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_UnplannedIssueJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationArea"); - - b.Property("HandledFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationCode"); - - b.Property("HandledFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationErpCode"); - - b.Property("HandledFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationGroup"); - - b.Property("HandledFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromWarehouseCode"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationArea"); - - b.Property("RecommendFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationCode"); - - b.Property("RecommendFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationErpCode"); - - b.Property("RecommendFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationGroup"); - - b.Property("RecommendFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromWarehouseCode"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_UnplannedIssueJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedIssueRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationArea"); - - b.Property("HandledFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationCode"); - - b.Property("HandledFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationErpCode"); - - b.Property("HandledFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromLocationGroup"); - - b.Property("HandledFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledFromWarehouseCode"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendFromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationArea"); - - b.Property("RecommendFromLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationCode"); - - b.Property("RecommendFromLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationErpCode"); - - b.Property("RecommendFromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromLocationGroup"); - - b.Property("RecommendFromWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendFromWarehouseCode"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedIssueRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedIssueRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptTime") - .HasColumnType("datetime2"); - - b.Property("AcceptUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("AcceptUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("CompleteTime") - .HasColumnType("datetime2"); - - b.Property("CompleteUserId") - .HasColumnType("uniqueidentifier"); - - b.Property("CompleteUserName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("IsAutoComplete") - .ValueGeneratedOnAdd() - .HasColumnType("bit") - .HasDefaultValue(false); - - b.Property("JobDescription") - .HasMaxLength(1024) - .HasColumnType("nvarchar(1024)"); - - b.Property("JobStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("JobType") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Priority") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("PriorityIncrement") - .ValueGeneratedOnAdd() - .HasColumnType("int") - .HasDefaultValue(0); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("UpStreamJobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WarehouseCode") - .HasColumnType("nvarchar(max)"); - - b.Property("WorkGroupCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Job_UnplannedReceiptJob", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJobDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("HandledToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationArea"); - - b.Property("HandledToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationCode"); - - b.Property("HandledToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationErpCode"); - - b.Property("HandledToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationGroup"); - - b.Property("HandledToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("RecommendToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationArea"); - - b.Property("RecommendToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationCode"); - - b.Property("RecommendToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationErpCode"); - - b.Property("RecommendToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationGroup"); - - b.Property("RecommendToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToWarehouseCode"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.ToTable("Job_UnplannedReceiptJobDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("UnplannedReceiptRequestNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("HandledArriveDate") - .HasColumnType("datetime2"); - - b.Property("HandledContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledContainerCode"); - - b.Property("HandledExpireDate") - .HasColumnType("datetime2"); - - b.Property("HandledLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledLot"); - - b.Property("HandledPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledPackingCode"); - - b.Property("HandledProduceDate") - .HasColumnType("datetime2"); - - b.Property("HandledQty") - .HasColumnType("decimal(18,6)"); - - b.Property("HandledSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledSupplierBatch"); - - b.Property("HandledToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationArea"); - - b.Property("HandledToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationCode"); - - b.Property("HandledToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationErpCode"); - - b.Property("HandledToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToLocationGroup"); - - b.Property("HandledToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("HandledToWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("ReasonCode") - .HasColumnType("nvarchar(max)"); - - b.Property("RecommendArriveDate") - .HasColumnType("datetime2"); - - b.Property("RecommendContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendContainerCode"); - - b.Property("RecommendExpireDate") - .HasColumnType("datetime2"); - - b.Property("RecommendLot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendLot"); - - b.Property("RecommendPackingCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendPackingCode"); - - b.Property("RecommendProduceDate") - .HasColumnType("datetime2"); - - b.Property("RecommendQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RecommendSupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendSupplierBatch"); - - b.Property("RecommendToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationArea"); - - b.Property("RecommendToLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationCode"); - - b.Property("RecommendToLocationErpCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationErpCode"); - - b.Property("RecommendToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToLocationGroup"); - - b.Property("RecommendToWarehouseCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("RecommendToWarehouseCode"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("AutoAgree") - .HasColumnType("bit"); - - b.Property("AutoCompleteJob") - .HasColumnType("bit"); - - b.Property("AutoHandle") - .HasColumnType("bit"); - - b.Property("AutoSubmit") - .HasColumnType("bit"); - - b.Property("BuildDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("DeptCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DeptName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("DirectCreateNote") - .HasColumnType("bit"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("RequestStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_UnplannedReceiptRequest", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("ContainerCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ContainerCode"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationArea"); - - b.Property("LocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationCode"); - - b.Property("LocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationErpCode"); - - b.Property("LocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("LocationGroup"); - - b.Property("Lot") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Lot"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("PackingCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("PackingCode"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("Status") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("WarehouseCode"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "PackingCode", "ItemCode", "Lot", "Status") - .IsUnique() - .HasFilter("[Lot] IS NOT NULL"); - - b.ToTable("Store_UnplannedReceiptRequestDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("JobNumber") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("JobNumber"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("SupplierCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WarehouseTransferNote", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ArriveDate") - .HasColumnType("datetime2"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("ExpireDate") - .HasColumnType("datetime2"); - - b.Property("FromContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("FromLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationArea"); - - b.Property("FromLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationCode"); - - b.Property("FromLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationErpCode"); - - b.Property("FromLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromLocationGroup"); - - b.Property("FromLot") - .HasColumnType("nvarchar(max)"); - - b.Property("FromPackingCode") - .HasColumnType("nvarchar(450)"); - - b.Property("FromStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("FromWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("FromWarehouseCode"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("ProduceDate") - .HasColumnType("datetime2"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Reason") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("StdPackQty") - .HasColumnType("decimal(18,6)"); - - b.Property("SupplierBatch") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("SupplierBatch"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("ToContainerCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToLocationArea") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationArea"); - - b.Property("ToLocationCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationCode"); - - b.Property("ToLocationErpCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationErpCode"); - - b.Property("ToLocationGroup") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToLocationGroup"); - - b.Property("ToLot") - .HasColumnType("nvarchar(max)"); - - b.Property("ToPackingCode") - .HasColumnType("nvarchar(max)"); - - b.Property("ToStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("ToWarehouseCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ToWarehouseCode"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode") - .IsUnique() - .HasFilter("[FromPackingCode] IS NOT NULL"); - - b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("ActiveDate") - .HasColumnType("datetime2"); - - b.Property("ConcurrencyStamp") - .IsConcurrencyToken() - .HasMaxLength(40) - .HasColumnType("nvarchar(40)") - .HasColumnName("ConcurrencyStamp"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ExtraProperties") - .HasColumnType("nvarchar(max)") - .HasColumnName("ExtraProperties"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.Property("Type") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Uom") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Uom"); - - b.Property("WoStatus") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkOrderId") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("WorkStation") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Worker") - .HasColumnType("nvarchar(max)"); - - b.HasKey("Id"); - - b.HasIndex("Number") - .IsUnique(); - - b.ToTable("Store_WorkOrder", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.Property("Id") - .HasColumnType("uniqueidentifier"); - - b.Property("CreationTime") - .HasColumnType("datetime2") - .HasColumnName("CreationTime"); - - b.Property("CreatorId") - .HasColumnType("uniqueidentifier") - .HasColumnName("CreatorId"); - - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); - - b.Property("LastModificationTime") - .HasColumnType("datetime2") - .HasColumnName("LastModificationTime"); - - b.Property("LastModifierId") - .HasColumnType("uniqueidentifier") - .HasColumnName("LastModifierId"); - - b.Property("MasterID") - .HasColumnType("uniqueidentifier"); - - b.Property("Number") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("Number"); - - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawLocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("RawQty") - .HasColumnType("decimal(18,6)"); - - b.Property("RawUom") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Remark") - .HasMaxLength(3072) - .HasColumnType("nvarchar(3072)") - .HasColumnName("Remark"); - - b.Property("TenantId") - .HasColumnType("uniqueidentifier") - .HasColumnName("TenantId"); - - b.HasKey("Id"); - - b.HasIndex("MasterID"); - - b.HasIndex("Number", "ItemCode") - .IsUnique(); - - b.ToTable("Store_WorkOrderDetail", (string)null); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CheckJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CountPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJobSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectJob", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNoteSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectNote", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequestSummaryDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InspectRequest", null) - .WithMany("SummaryDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IsolationNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.IssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlanDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleMaterialDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("MaterialDetails") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SaleOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsnDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.TransferRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJobDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequestDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNoteDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => - { - b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) - .WithMany("Details") - .HasForeignKey("MasterID") - .OnDelete(DeleteBehavior.Cascade) - .IsRequired(); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.BackFlushNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CheckJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ContainerBindNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountAdjustRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CountPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.CustomerReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.DeliverRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectJob", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectNote", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InspectRequest", b => - { - b.Navigation("Details"); - - b.Navigation("SummaryDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryInitialNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.InventoryTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IsolationNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.IssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ItemTransformRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisDeliverNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.JisProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.MaterialRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.NoOkConvertOkNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.OfflineSettlementNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PreparationPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionPlan", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductionReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductL7PartsNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductReceiveJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleNote", b => - { - b.Navigation("Details"); - - b.Navigation("MaterialDetails"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ProductRecycleRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PurchaseReturnRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.PutawayRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ReceiptAbnormalNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.RecycledMaterialReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SaleOrder", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.ScrapRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.TransferRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedIssueRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptJob", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.UnplannedReceiptRequest", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WarehouseTransferNote", b => - { - b.Navigation("Details"); - }); - - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => - { - b.Navigation("Details"); - }); -#pragma warning restore 612, 618 - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230401163806_Added_AddPurchaseOrder.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230401163806_Added_AddPurchaseOrder.cs deleted file mode 100644 index c673fa53d..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230401163806_Added_AddPurchaseOrder.cs +++ /dev/null @@ -1,6905 +0,0 @@ -using System; -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - public partial class Added_AddPurchaseOrder : Migration - { - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.RenameColumn( - name: "RecommendWarehouseCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "RecommendToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationGroup", - table: "Job_UnplannedReceiptJobDetail", - newName: "RecommendToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationErpCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "RecommendToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "RecommendToLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationArea", - table: "Job_UnplannedReceiptJobDetail", - newName: "RecommendToLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledWarehouseCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "HandledToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationGroup", - table: "Job_UnplannedReceiptJobDetail", - newName: "HandledToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledLocationErpCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "HandledToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "HandledToLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationArea", - table: "Job_UnplannedReceiptJobDetail", - newName: "HandledToLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendWarehouseCode", - table: "Job_UnplannedIssueJobDetail", - newName: "RecommendFromWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationGroup", - table: "Job_UnplannedIssueJobDetail", - newName: "RecommendFromLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationErpCode", - table: "Job_UnplannedIssueJobDetail", - newName: "RecommendFromLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationCode", - table: "Job_UnplannedIssueJobDetail", - newName: "RecommendFromLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationArea", - table: "Job_UnplannedIssueJobDetail", - newName: "RecommendFromLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledWarehouseCode", - table: "Job_UnplannedIssueJobDetail", - newName: "HandledFromWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationGroup", - table: "Job_UnplannedIssueJobDetail", - newName: "HandledFromLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledLocationErpCode", - table: "Job_UnplannedIssueJobDetail", - newName: "HandledFromLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationCode", - table: "Job_UnplannedIssueJobDetail", - newName: "HandledFromLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationArea", - table: "Job_UnplannedIssueJobDetail", - newName: "HandledFromLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendWarehouseCode", - table: "Job_PutawayJobDetail", - newName: "RecommendToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationGroup", - table: "Job_PutawayJobDetail", - newName: "RecommendToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationErpCode", - table: "Job_PutawayJobDetail", - newName: "RecommendToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationCode", - table: "Job_PutawayJobDetail", - newName: "RecommendToLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationArea", - table: "Job_PutawayJobDetail", - newName: "RecommendToLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledWarehouseCode", - table: "Job_PutawayJobDetail", - newName: "HandledToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationGroup", - table: "Job_PutawayJobDetail", - newName: "HandledToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledLocationErpCode", - table: "Job_PutawayJobDetail", - newName: "HandledToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationCode", - table: "Job_PutawayJobDetail", - newName: "HandledToLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationArea", - table: "Job_PutawayJobDetail", - newName: "HandledToLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendWarehouseCode", - table: "Job_PurchaseReturnJobDetail", - newName: "RecommendFromWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationGroup", - table: "Job_PurchaseReturnJobDetail", - newName: "RecommendFromLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationErpCode", - table: "Job_PurchaseReturnJobDetail", - newName: "RecommendFromLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationCode", - table: "Job_PurchaseReturnJobDetail", - newName: "RecommendFromLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationArea", - table: "Job_PurchaseReturnJobDetail", - newName: "RecommendFromLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledWarehouseCode", - table: "Job_PurchaseReturnJobDetail", - newName: "HandledFromWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationGroup", - table: "Job_PurchaseReturnJobDetail", - newName: "HandledFromLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledLocationErpCode", - table: "Job_PurchaseReturnJobDetail", - newName: "HandledFromLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationCode", - table: "Job_PurchaseReturnJobDetail", - newName: "HandledFromLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationArea", - table: "Job_PurchaseReturnJobDetail", - newName: "HandledFromLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendWarehouseCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "RecommendToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationGroup", - table: "Job_PurchaseReceiptJobDetail", - newName: "RecommendToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationErpCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "RecommendToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "RecommendToLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationArea", - table: "Job_PurchaseReceiptJobDetail", - newName: "RecommendToLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledWarehouseCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "HandledToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationGroup", - table: "Job_PurchaseReceiptJobDetail", - newName: "HandledToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledLocationErpCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "HandledToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "HandledToLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationArea", - table: "Job_PurchaseReceiptJobDetail", - newName: "HandledToLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendWarehouseCode", - table: "Job_ProductReceiveJobDetail", - newName: "RecommendToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationGroup", - table: "Job_ProductReceiveJobDetail", - newName: "RecommendToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationErpCode", - table: "Job_ProductReceiveJobDetail", - newName: "RecommendToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationCode", - table: "Job_ProductReceiveJobDetail", - newName: "RecommendToLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationArea", - table: "Job_ProductReceiveJobDetail", - newName: "RecommendToLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledWarehouseCode", - table: "Job_ProductReceiveJobDetail", - newName: "HandledToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationGroup", - table: "Job_ProductReceiveJobDetail", - newName: "HandledToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledLocationErpCode", - table: "Job_ProductReceiveJobDetail", - newName: "HandledToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationCode", - table: "Job_ProductReceiveJobDetail", - newName: "HandledToLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationArea", - table: "Job_ProductReceiveJobDetail", - newName: "HandledToLocationArea"); - - migrationBuilder.RenameColumn( - name: "ToWarehouseCode", - table: "Job_ProductionReturnJobDetail", - newName: "RecommendToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "ToLocationGroup", - table: "Job_ProductionReturnJobDetail", - newName: "RecommendToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "ToLocationErpCode", - table: "Job_ProductionReturnJobDetail", - newName: "RecommendToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "ToLocationCode", - table: "Job_ProductionReturnJobDetail", - newName: "RecommendToLocationCode"); - - migrationBuilder.RenameColumn( - name: "ToLocationArea", - table: "Job_ProductionReturnJobDetail", - newName: "RecommendToLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendWarehouseCode", - table: "Job_ProductionReturnJobDetail", - newName: "HandledToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationGroup", - table: "Job_ProductionReturnJobDetail", - newName: "HandledToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationErpCode", - table: "Job_ProductionReturnJobDetail", - newName: "HandledToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationCode", - table: "Job_ProductionReturnJobDetail", - newName: "HandledToLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationArea", - table: "Job_ProductionReturnJobDetail", - newName: "HandledToLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledWarehouseCode", - table: "Job_ProductionReturnJobDetail", - newName: "FromWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationGroup", - table: "Job_ProductionReturnJobDetail", - newName: "FromLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledLocationErpCode", - table: "Job_ProductionReturnJobDetail", - newName: "FromLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationCode", - table: "Job_ProductionReturnJobDetail", - newName: "FromLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationArea", - table: "Job_ProductionReturnJobDetail", - newName: "FromLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendWarehouseCode", - table: "Job_IssueJobDetail", - newName: "RecommendFromWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationGroup", - table: "Job_IssueJobDetail", - newName: "RecommendFromLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationErpCode", - table: "Job_IssueJobDetail", - newName: "RecommendFromLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationCode", - table: "Job_IssueJobDetail", - newName: "RecommendFromLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationArea", - table: "Job_IssueJobDetail", - newName: "RecommendFromLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledWarehouseCode", - table: "Job_IssueJobDetail", - newName: "HandledFromWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationGroup", - table: "Job_IssueJobDetail", - newName: "HandledFromLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledLocationErpCode", - table: "Job_IssueJobDetail", - newName: "HandledFromLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationCode", - table: "Job_IssueJobDetail", - newName: "HandledFromLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationArea", - table: "Job_IssueJobDetail", - newName: "HandledFromLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendWarehouseCode", - table: "Job_DeliverJobDetail", - newName: "RecommendFromWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationGroup", - table: "Job_DeliverJobDetail", - newName: "RecommendFromLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationErpCode", - table: "Job_DeliverJobDetail", - newName: "RecommendFromLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationCode", - table: "Job_DeliverJobDetail", - newName: "RecommendFromLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendLocationArea", - table: "Job_DeliverJobDetail", - newName: "RecommendFromLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledWarehouseCode", - table: "Job_DeliverJobDetail", - newName: "HandledFromWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationGroup", - table: "Job_DeliverJobDetail", - newName: "HandledFromLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledLocationErpCode", - table: "Job_DeliverJobDetail", - newName: "HandledFromLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationCode", - table: "Job_DeliverJobDetail", - newName: "HandledFromLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledLocationArea", - table: "Job_DeliverJobDetail", - newName: "HandledFromLocationArea"); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_WorkOrderDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_WorkOrder", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_WarehouseTransferNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedReceiptRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "HandledArriveDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledExpireDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledProduceDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledQty", - table: "Store_UnplannedReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "HandledSupplierBatch", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationArea", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationErpCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationGroup", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToWarehouseCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendArriveDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendExpireDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendProduceDate", - table: "Store_UnplannedReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendQty", - table: "Store_UnplannedReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RecommendSupplierBatch", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationArea", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationErpCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationGroup", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToWarehouseCode", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedReceiptNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedIssueRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "HandledArriveDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledExpireDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledFromLocationArea", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationErpCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationGroup", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromWarehouseCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledProduceDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledQty", - table: "Store_UnplannedIssueNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "HandledSupplierBatch", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendArriveDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendExpireDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationArea", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationErpCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationGroup", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromWarehouseCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendProduceDate", - table: "Store_UnplannedIssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendQty", - table: "Store_UnplannedIssueNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RecommendSupplierBatch", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedIssueNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_TransferRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_TransferRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_TransferNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_TransferNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_SupplierAsnDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_SupplierAsn", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ScrapRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ScrapRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ScrapNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromPackingCode", - table: "Store_ScrapNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ScrapNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_SaleOrderDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_SaleOrder", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_RecycledMaterialReceiptNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ReceiptAbnormalNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PutawayRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PutawayRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PutawayNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "HandledArriveDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledExpireDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledProduceDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledQty", - table: "Store_PutawayNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "HandledSupplierBatch", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationArea", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationErpCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToWarehouseCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendArriveDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendExpireDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendProduceDate", - table: "Store_PutawayNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendQty", - table: "Store_PutawayNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RecommendSupplierBatch", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationArea", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationErpCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationGroup", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToWarehouseCode", - table: "Store_PutawayNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PutawayNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReturnRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "HandledArriveDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledExpireDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledFromLocationArea", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationErpCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationGroup", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromWarehouseCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledProduceDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledQty", - table: "Store_PurchaseReturnNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "HandledSupplierBatch", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendArriveDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendExpireDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationArea", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationErpCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationGroup", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromWarehouseCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendProduceDate", - table: "Store_PurchaseReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendQty", - table: "Store_PurchaseReturnNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RecommendSupplierBatch", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReturnNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReceiptRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "HandledArriveDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledExpireDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledProduceDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledQty", - table: "Store_PurchaseReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "HandledSupplierBatch", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationArea", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationErpCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationGroup", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToWarehouseCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendArriveDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendExpireDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendProduceDate", - table: "Store_PurchaseReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendQty", - table: "Store_PurchaseReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RecommendSupplierBatch", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationArea", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationErpCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationGroup", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToWarehouseCode", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReceiptNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "PlanUserCode", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "Ctype", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "ExpireDate", - table: "Store_PurchaseOrderDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "Lot", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "OrderRemark", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "PlanArriveDate", - table: "Store_PurchaseOrderDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "ProduceDate", - table: "Store_PurchaseOrderDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseOrder", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductRecycleRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductRecycleNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductReceiptRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "HandledArriveDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledExpireDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledProduceDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledQty", - table: "Store_ProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "HandledSupplierBatch", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationArea", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationErpCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationGroup", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToWarehouseCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendArriveDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendExpireDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendProduceDate", - table: "Store_ProductReceiptNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendQty", - table: "Store_ProductReceiptNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RecommendSupplierBatch", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationArea", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationErpCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationGroup", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToWarehouseCode", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductReceiptNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProductNo", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Position", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "L7Part", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Configuration", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(450)", - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductL7PartsNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionReturnRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "HandledArriveDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledExpireDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledProduceDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledQty", - table: "Store_ProductionReturnNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "HandledSupplierBatch", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationArea", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationErpCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToLocationGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledToWarehouseCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendArriveDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendExpireDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendProduceDate", - table: "Store_ProductionReturnNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendQty", - table: "Store_ProductionReturnNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RecommendSupplierBatch", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationArea", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationErpCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToLocationGroup", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendToWarehouseCode", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionReturnNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionPlanDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionPlan", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PreparationPlanDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PreparationPlan", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_OfflineSettlementNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_NoOkConvertOkNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_MaterialRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_MaterialRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_JisProductReceiptNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_JisDeliverNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ItemTransformRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ItemTransformNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_IssueNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "HandledArriveDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledExpireDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledFromLocationArea", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationErpCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromWarehouseCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledProduceDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledQty", - table: "Store_IssueNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "HandledSupplierBatch", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendArriveDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendExpireDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationArea", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationErpCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationGroup", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromWarehouseCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendProduceDate", - table: "Store_IssueNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendQty", - table: "Store_IssueNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RecommendSupplierBatch", - table: "Store_IssueNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_IssueNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_IsolationNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_IsolationNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InventoryTransferNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InventoryInitialNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectAbnormalNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ExchangeData", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Number", - table: "Store_ExchangeData", - type: "bigint", - nullable: false, - oldClrType: typeof(long), - oldType: "bigint") - .OldAnnotation("SqlServer:Identity", "1, 1"); - - migrationBuilder.AlterColumn( - name: "ErrorMessage", - table: "Store_ExchangeData", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EffectiveDate", - table: "Store_ExchangeData", - type: "datetime2", - nullable: false, - oldClrType: typeof(DateTime), - oldType: "datetime2(7)"); - - migrationBuilder.AlterColumn( - name: "DataAction", - table: "Store_ExchangeData", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverPlanDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverPlan", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "HandledArriveDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledContainerCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledExpireDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledFromLocationArea", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationErpCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromLocationGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledFromWarehouseCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledLot", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledPackingCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "HandledProduceDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "HandledQty", - table: "Store_DeliverNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "HandledSupplierBatch", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendArriveDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendContainerCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendExpireDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationArea", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationErpCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromLocationGroup", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendFromWarehouseCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendLot", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendPackingCode", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AddColumn( - name: "RecommendProduceDate", - table: "Store_DeliverNoteDetail", - type: "datetime2", - nullable: false, - defaultValue: new DateTime(1, 1, 1, 0, 0, 0, 0, DateTimeKind.Unspecified)); - - migrationBuilder.AddColumn( - name: "RecommendQty", - table: "Store_DeliverNoteDetail", - type: "decimal(18,6)", - nullable: false, - defaultValue: 0m); - - migrationBuilder.AddColumn( - name: "RecommendSupplierBatch", - table: "Store_DeliverNoteDetail", - type: "nvarchar(64)", - maxLength: 64, - nullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CustomerReturnNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CustomerAsnDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CustomerAsn", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountPlanDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountPlan", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountAdjustRequest", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountAdjustNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ContainerBindNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_BackFlushNote", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_UnplannedReceiptJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_UnplannedReceiptJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_UnplannedIssueJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_UnplannedIssueJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PutawayJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PutawayJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PurchaseReturnJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PurchaseReturnJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PurchaseReceiptJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PurchaseReceiptJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_ProductReceiveJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_ProductReceiveJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_ProductionReturnJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_ProductionReturnJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_JisDeliverJobDetail", - type: "nvarchar(max)", - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_JisDeliverJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_JisDeliverJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_IssueJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_IssueJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_InspectJobSummaryDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_InspectJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_InspectJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_DeliverJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_DeliverJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_CountJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_CountJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_CheckJobDetail", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_CheckJob", - type: "nvarchar(3072)", - maxLength: 3072, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(max)", - oldMaxLength: 4096, - oldNullable: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "HandledArriveDate", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledExpireDate", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledProduceDate", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledSupplierBatch", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationArea", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationErpCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationGroup", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToWarehouseCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendArriveDate", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendExpireDate", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendProduceDate", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendSupplierBatch", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationArea", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationErpCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationGroup", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToWarehouseCode", - table: "Store_UnplannedReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledArriveDate", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledExpireDate", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationArea", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationErpCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationGroup", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromWarehouseCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledProduceDate", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledSupplierBatch", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendArriveDate", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendExpireDate", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationArea", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationErpCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationGroup", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromWarehouseCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendProduceDate", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendSupplierBatch", - table: "Store_UnplannedIssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledArriveDate", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledExpireDate", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledProduceDate", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledSupplierBatch", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationArea", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationErpCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationGroup", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToWarehouseCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendArriveDate", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendExpireDate", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendProduceDate", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendSupplierBatch", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationArea", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationErpCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationGroup", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToWarehouseCode", - table: "Store_PutawayNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledArriveDate", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledExpireDate", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationArea", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationErpCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationGroup", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromWarehouseCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledProduceDate", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledSupplierBatch", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendArriveDate", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendExpireDate", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationArea", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationErpCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationGroup", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromWarehouseCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendProduceDate", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendSupplierBatch", - table: "Store_PurchaseReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledArriveDate", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledExpireDate", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledProduceDate", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledSupplierBatch", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationArea", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationErpCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationGroup", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToWarehouseCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendArriveDate", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendExpireDate", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendProduceDate", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendSupplierBatch", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationArea", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationErpCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationGroup", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToWarehouseCode", - table: "Store_PurchaseReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "PlanUserCode", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "Ctype", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "ExpireDate", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "Lot", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "OrderRemark", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "PlanArriveDate", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "ProduceDate", - table: "Store_PurchaseOrderDetail"); - - migrationBuilder.DropColumn( - name: "HandledArriveDate", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledExpireDate", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledProduceDate", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledSupplierBatch", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationArea", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationErpCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationGroup", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToWarehouseCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendArriveDate", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendExpireDate", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendProduceDate", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendSupplierBatch", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationArea", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationErpCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationGroup", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToWarehouseCode", - table: "Store_ProductReceiptNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledArriveDate", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledExpireDate", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledProduceDate", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledSupplierBatch", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationArea", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationErpCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToLocationGroup", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledToWarehouseCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendArriveDate", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendExpireDate", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendProduceDate", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendSupplierBatch", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationArea", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationErpCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToLocationGroup", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendToWarehouseCode", - table: "Store_ProductionReturnNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledArriveDate", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledExpireDate", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationArea", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationErpCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationGroup", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromWarehouseCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledProduceDate", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledSupplierBatch", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendArriveDate", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendExpireDate", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationArea", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationErpCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationGroup", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromWarehouseCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendProduceDate", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendSupplierBatch", - table: "Store_IssueNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledArriveDate", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledContainerCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledExpireDate", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationArea", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationErpCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromLocationGroup", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledFromWarehouseCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledLot", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledPackingCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledProduceDate", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledQty", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "HandledSupplierBatch", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendArriveDate", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendContainerCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendExpireDate", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationArea", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationErpCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromLocationGroup", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendFromWarehouseCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendLot", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendPackingCode", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendProduceDate", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendQty", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.DropColumn( - name: "RecommendSupplierBatch", - table: "Store_DeliverNoteDetail"); - - migrationBuilder.RenameColumn( - name: "RecommendToWarehouseCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "RecommendWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationGroup", - table: "Job_UnplannedReceiptJobDetail", - newName: "RecommendLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationErpCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "RecommendLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "RecommendLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationArea", - table: "Job_UnplannedReceiptJobDetail", - newName: "RecommendLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledToWarehouseCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "HandledWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationGroup", - table: "Job_UnplannedReceiptJobDetail", - newName: "HandledLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationErpCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "HandledLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationCode", - table: "Job_UnplannedReceiptJobDetail", - newName: "HandledLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationArea", - table: "Job_UnplannedReceiptJobDetail", - newName: "HandledLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendFromWarehouseCode", - table: "Job_UnplannedIssueJobDetail", - newName: "RecommendWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationGroup", - table: "Job_UnplannedIssueJobDetail", - newName: "RecommendLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationErpCode", - table: "Job_UnplannedIssueJobDetail", - newName: "RecommendLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationCode", - table: "Job_UnplannedIssueJobDetail", - newName: "RecommendLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationArea", - table: "Job_UnplannedIssueJobDetail", - newName: "RecommendLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledFromWarehouseCode", - table: "Job_UnplannedIssueJobDetail", - newName: "HandledWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationGroup", - table: "Job_UnplannedIssueJobDetail", - newName: "HandledLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationErpCode", - table: "Job_UnplannedIssueJobDetail", - newName: "HandledLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationCode", - table: "Job_UnplannedIssueJobDetail", - newName: "HandledLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationArea", - table: "Job_UnplannedIssueJobDetail", - newName: "HandledLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendToWarehouseCode", - table: "Job_PutawayJobDetail", - newName: "RecommendWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationGroup", - table: "Job_PutawayJobDetail", - newName: "RecommendLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationErpCode", - table: "Job_PutawayJobDetail", - newName: "RecommendLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationCode", - table: "Job_PutawayJobDetail", - newName: "RecommendLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationArea", - table: "Job_PutawayJobDetail", - newName: "RecommendLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledToWarehouseCode", - table: "Job_PutawayJobDetail", - newName: "HandledWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationGroup", - table: "Job_PutawayJobDetail", - newName: "HandledLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationErpCode", - table: "Job_PutawayJobDetail", - newName: "HandledLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationCode", - table: "Job_PutawayJobDetail", - newName: "HandledLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationArea", - table: "Job_PutawayJobDetail", - newName: "HandledLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendFromWarehouseCode", - table: "Job_PurchaseReturnJobDetail", - newName: "RecommendWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationGroup", - table: "Job_PurchaseReturnJobDetail", - newName: "RecommendLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationErpCode", - table: "Job_PurchaseReturnJobDetail", - newName: "RecommendLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationCode", - table: "Job_PurchaseReturnJobDetail", - newName: "RecommendLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationArea", - table: "Job_PurchaseReturnJobDetail", - newName: "RecommendLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledFromWarehouseCode", - table: "Job_PurchaseReturnJobDetail", - newName: "HandledWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationGroup", - table: "Job_PurchaseReturnJobDetail", - newName: "HandledLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationErpCode", - table: "Job_PurchaseReturnJobDetail", - newName: "HandledLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationCode", - table: "Job_PurchaseReturnJobDetail", - newName: "HandledLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationArea", - table: "Job_PurchaseReturnJobDetail", - newName: "HandledLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendToWarehouseCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "RecommendWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationGroup", - table: "Job_PurchaseReceiptJobDetail", - newName: "RecommendLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationErpCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "RecommendLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "RecommendLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationArea", - table: "Job_PurchaseReceiptJobDetail", - newName: "RecommendLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledToWarehouseCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "HandledWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationGroup", - table: "Job_PurchaseReceiptJobDetail", - newName: "HandledLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationErpCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "HandledLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationCode", - table: "Job_PurchaseReceiptJobDetail", - newName: "HandledLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationArea", - table: "Job_PurchaseReceiptJobDetail", - newName: "HandledLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendToWarehouseCode", - table: "Job_ProductReceiveJobDetail", - newName: "RecommendWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationGroup", - table: "Job_ProductReceiveJobDetail", - newName: "RecommendLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationErpCode", - table: "Job_ProductReceiveJobDetail", - newName: "RecommendLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationCode", - table: "Job_ProductReceiveJobDetail", - newName: "RecommendLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationArea", - table: "Job_ProductReceiveJobDetail", - newName: "RecommendLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledToWarehouseCode", - table: "Job_ProductReceiveJobDetail", - newName: "HandledWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationGroup", - table: "Job_ProductReceiveJobDetail", - newName: "HandledLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationErpCode", - table: "Job_ProductReceiveJobDetail", - newName: "HandledLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationCode", - table: "Job_ProductReceiveJobDetail", - newName: "HandledLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationArea", - table: "Job_ProductReceiveJobDetail", - newName: "HandledLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendToWarehouseCode", - table: "Job_ProductionReturnJobDetail", - newName: "ToWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationGroup", - table: "Job_ProductionReturnJobDetail", - newName: "ToLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationErpCode", - table: "Job_ProductionReturnJobDetail", - newName: "ToLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationCode", - table: "Job_ProductionReturnJobDetail", - newName: "ToLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendToLocationArea", - table: "Job_ProductionReturnJobDetail", - newName: "ToLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledToWarehouseCode", - table: "Job_ProductionReturnJobDetail", - newName: "RecommendWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationGroup", - table: "Job_ProductionReturnJobDetail", - newName: "RecommendLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationErpCode", - table: "Job_ProductionReturnJobDetail", - newName: "RecommendLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationCode", - table: "Job_ProductionReturnJobDetail", - newName: "RecommendLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledToLocationArea", - table: "Job_ProductionReturnJobDetail", - newName: "RecommendLocationArea"); - - migrationBuilder.RenameColumn( - name: "FromWarehouseCode", - table: "Job_ProductionReturnJobDetail", - newName: "HandledWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "FromLocationGroup", - table: "Job_ProductionReturnJobDetail", - newName: "HandledLocationGroup"); - - migrationBuilder.RenameColumn( - name: "FromLocationErpCode", - table: "Job_ProductionReturnJobDetail", - newName: "HandledLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "FromLocationCode", - table: "Job_ProductionReturnJobDetail", - newName: "HandledLocationCode"); - - migrationBuilder.RenameColumn( - name: "FromLocationArea", - table: "Job_ProductionReturnJobDetail", - newName: "HandledLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendFromWarehouseCode", - table: "Job_IssueJobDetail", - newName: "RecommendWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationGroup", - table: "Job_IssueJobDetail", - newName: "RecommendLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationErpCode", - table: "Job_IssueJobDetail", - newName: "RecommendLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationCode", - table: "Job_IssueJobDetail", - newName: "RecommendLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationArea", - table: "Job_IssueJobDetail", - newName: "RecommendLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledFromWarehouseCode", - table: "Job_IssueJobDetail", - newName: "HandledWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationGroup", - table: "Job_IssueJobDetail", - newName: "HandledLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationErpCode", - table: "Job_IssueJobDetail", - newName: "HandledLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationCode", - table: "Job_IssueJobDetail", - newName: "HandledLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationArea", - table: "Job_IssueJobDetail", - newName: "HandledLocationArea"); - - migrationBuilder.RenameColumn( - name: "RecommendFromWarehouseCode", - table: "Job_DeliverJobDetail", - newName: "RecommendWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationGroup", - table: "Job_DeliverJobDetail", - newName: "RecommendLocationGroup"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationErpCode", - table: "Job_DeliverJobDetail", - newName: "RecommendLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationCode", - table: "Job_DeliverJobDetail", - newName: "RecommendLocationCode"); - - migrationBuilder.RenameColumn( - name: "RecommendFromLocationArea", - table: "Job_DeliverJobDetail", - newName: "RecommendLocationArea"); - - migrationBuilder.RenameColumn( - name: "HandledFromWarehouseCode", - table: "Job_DeliverJobDetail", - newName: "HandledWarehouseCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationGroup", - table: "Job_DeliverJobDetail", - newName: "HandledLocationGroup"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationErpCode", - table: "Job_DeliverJobDetail", - newName: "HandledLocationErpCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationCode", - table: "Job_DeliverJobDetail", - newName: "HandledLocationCode"); - - migrationBuilder.RenameColumn( - name: "HandledFromLocationArea", - table: "Job_DeliverJobDetail", - newName: "HandledLocationArea"); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_WorkOrderDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_WorkOrder", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_WarehouseTransferNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_WarehouseTransferNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedReceiptRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedReceiptRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedReceiptNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedReceiptNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedIssueRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedIssueRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedIssueNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_UnplannedIssueNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_TransferRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_TransferRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_TransferNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_TransferNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_SupplierAsnDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_SupplierAsn", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ScrapRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ScrapRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ScrapNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "FromPackingCode", - table: "Store_ScrapNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ScrapNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_SaleOrderDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_SaleOrder", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_RecycledMaterialReceiptNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_RecycledMaterialReceiptNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ReceiptAbnormalNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ReceiptAbnormalNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PutawayRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PutawayRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PutawayNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PutawayNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReturnRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReturnRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReturnNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReturnNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReceiptRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReceiptRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReceiptNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseReceiptNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseOrderDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PurchaseOrder", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductRecycleRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductRecycleRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductRecycleNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductRecycleNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductRecycleMaterialDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductReceiptRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductReceiptRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductReceiptNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductReceiptNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "ProductNo", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Position", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "L7Part", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Configuration", - table: "Store_ProductL7PartsNoteDetail", - type: "nvarchar(450)", - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductL7PartsNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionReturnRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionReturnRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionReturnNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionReturnNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionPlanDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ProductionPlan", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PreparationPlanDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_PreparationPlan", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_OfflineSettlementNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_OfflineSettlementNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_NoOkConvertOkNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_NoOkConvertOkNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_MaterialRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_MaterialRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_JisProductReceiptNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_JisProductReceiptNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_JisDeliverNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_JisDeliverNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ItemTransformRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ItemTransformRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ItemTransformNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ItemTransformNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_IssueNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_IssueNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_IsolationNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_IsolationNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InventoryTransferNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InventoryTransferNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InventoryInitialNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InventoryInitialNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectRequestSummaryDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectNoteSummaryDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectAbnormalNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_InspectAbnormalNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ExchangeData", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Number", - table: "Store_ExchangeData", - type: "bigint", - nullable: false, - oldClrType: typeof(long), - oldType: "bigint") - .Annotation("SqlServer:Identity", "1, 1"); - - migrationBuilder.AlterColumn( - name: "ErrorMessage", - table: "Store_ExchangeData", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "EffectiveDate", - table: "Store_ExchangeData", - type: "datetime2(7)", - nullable: false, - oldClrType: typeof(DateTime), - oldType: "datetime2"); - - migrationBuilder.AlterColumn( - name: "DataAction", - table: "Store_ExchangeData", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - oldClrType: typeof(int), - oldType: "int"); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverPlanDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverPlan", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_DeliverNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CustomerReturnNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CustomerReturnNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CustomerAsnDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CustomerAsn", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountPlanDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountPlan", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountAdjustRequestDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountAdjustRequest", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountAdjustNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_CountAdjustNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ContainerBindNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_ContainerBindNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_BackFlushNoteDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Store_BackFlushNote", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_UnplannedReceiptJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_UnplannedReceiptJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_UnplannedIssueJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_UnplannedIssueJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PutawayJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PutawayJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PurchaseReturnJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PurchaseReturnJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PurchaseReceiptJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_PurchaseReceiptJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_ProductReceiveJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_ProductReceiveJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_ProductionReturnJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_ProductionReturnJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Status", - table: "Job_JisDeliverJobDetail", - type: "int", - nullable: false, - oldClrType: typeof(string), - oldType: "nvarchar(max)"); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_JisDeliverJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_JisDeliverJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_IssueJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_IssueJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_InspectJobSummaryDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_InspectJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_InspectJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_DeliverJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_DeliverJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_CountJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_CountJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_CheckJobDetail", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - - migrationBuilder.AlterColumn( - name: "Remark", - table: "Job_CheckJob", - type: "nvarchar(max)", - maxLength: 4096, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(3072)", - oldMaxLength: 3072, - oldNullable: true); - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230404020712_Added_Store_Add_SupplierAdress_SupplierName.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230404020712_Added_Store_Add_SupplierAdress_SupplierName.cs deleted file mode 100644 index eadaed488..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230404020712_Added_Store_Add_SupplierAdress_SupplierName.cs +++ /dev/null @@ -1,95 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - public partial class Added_Store_Add_SupplierAddress_SupplierName : Migration - { - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.AddColumn( - name: "SupplierAddress", - table: "Store_SupplierAsn", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierName", - table: "Store_SupplierAsn", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierAddress", - table: "Store_PurchaseReceiptRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierAddress", - table: "Store_PurchaseReceiptNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierName", - table: "Store_PurchaseReceiptNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierAddress", - table: "Store_PurchaseOrder", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierName", - table: "Store_PurchaseOrder", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "SupplierAddress", - table: "Job_PurchaseReceiptJob", - type: "nvarchar(max)", - nullable: true); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "SupplierAddress", - table: "Store_SupplierAsn"); - - migrationBuilder.DropColumn( - name: "SupplierName", - table: "Store_SupplierAsn"); - - migrationBuilder.DropColumn( - name: "SupplierAddress", - table: "Store_PurchaseReceiptRequest"); - - migrationBuilder.DropColumn( - name: "SupplierAddress", - table: "Store_PurchaseReceiptNote"); - - migrationBuilder.DropColumn( - name: "SupplierName", - table: "Store_PurchaseReceiptNote"); - - migrationBuilder.DropColumn( - name: "SupplierAddress", - table: "Store_PurchaseOrder"); - - migrationBuilder.DropColumn( - name: "SupplierName", - table: "Store_PurchaseOrder"); - - migrationBuilder.DropColumn( - name: "SupplierAddress", - table: "Job_PurchaseReceiptJob"); - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230412072454_Store_AddColumn.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230412072454_Store_AddColumn.cs deleted file mode 100644 index 93eaf0024..000000000 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230412072454_Store_AddColumn.cs +++ /dev/null @@ -1,68 +0,0 @@ -using Microsoft.EntityFrameworkCore.Migrations; - -#nullable disable - -namespace Win_in.Sfs.Wms.Store.Migrations -{ - public partial class Store_AddColumn : Migration - { - protected override void Up(MigrationBuilder migrationBuilder) - { - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_TransferNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: false, - defaultValue: "", - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64, - oldNullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptNote", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "WarehouseCode", - table: "Store_InspectRequest", - type: "nvarchar(max)", - nullable: true); - - migrationBuilder.AddColumn( - name: "CountPrint", - table: "Store_DeliverNote", - type: "int", - nullable: false, - defaultValue: 0); - } - - protected override void Down(MigrationBuilder migrationBuilder) - { - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_PurchaseReceiptNote"); - - migrationBuilder.DropColumn( - name: "WarehouseCode", - table: "Store_InspectRequest"); - - migrationBuilder.DropColumn( - name: "CountPrint", - table: "Store_DeliverNote"); - - migrationBuilder.AlterColumn( - name: "Type", - table: "Store_TransferNote", - type: "nvarchar(64)", - maxLength: 64, - nullable: true, - oldClrType: typeof(string), - oldType: "nvarchar(64)", - oldMaxLength: 64); - } - } -} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230412072454_Store_AddColumn.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223055707_temp.Designer.cs similarity index 96% rename from be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230412072454_Store_AddColumn.Designer.cs rename to be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223055707_temp.Designer.cs index 72ce9d5e6..7c029a486 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230412072454_Store_AddColumn.Designer.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223055707_temp.Designer.cs @@ -13,8 +13,8 @@ using Win_in.Sfs.Wms.Store.EntityFrameworkCore; namespace Win_in.Sfs.Wms.Store.Migrations { [DbContext(typeof(StoreDbContext))] - [Migration("20230412072454_Store_AddColumn")] - partial class Store_AddColumn + [Migration("20240223055707_temp")] + partial class temp { protected override void BuildTargetModel(ModelBuilder modelBuilder) { @@ -3924,6 +3924,10 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); + b.Property("TyrpNumber") + .IsRequired() + .HasColumnType("nvarchar(max)"); + b.Property("WriteTime") .HasColumnType("datetime2"); @@ -4791,6 +4795,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("decimal(18,6)") .HasDefaultValue(0m); + b.Property("InspectDate") + .HasColumnType("datetime2"); + b.Property("InspectQty") .ValueGeneratedOnAdd() .HasColumnType("decimal(18,6)") @@ -11234,6 +11241,7 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnName("TenantId"); b.Property("Type") + .IsRequired() .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -16859,6 +16867,152 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.ToTable("Store_ScrapRequestDetail", (string)null); }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SplitPackingRec", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ArrivalNoticNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasMaxLength(40) + .HasColumnType("nvarchar(40)") + .HasColumnName("ConcurrencyStamp"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("ExtraProperties") + .HasColumnType("nvarchar(max)") + .HasColumnName("ExtraProperties"); + + b.Property("FromLot") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromQty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)"); + + b.Property("FromStdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("FromTopPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromUom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ItemDesc1") + .HasMaxLength(1024) + .HasColumnType("nvarchar(1024)"); + + b.Property("ItemDesc2") + .HasMaxLength(1024) + .HasColumnType("nvarchar(1024)"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("LabelType") + .HasColumnType("int"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("OprType") + .HasColumnType("int"); + + b.Property("PurchaseInfo_AsnNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("PurchaseInfo_PoNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("PutOnShelfNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ReceiptRecNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Remark") + .HasColumnType("nvarchar(max)"); + + b.Property("TaskOrderNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("ToLot") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToQty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)"); + + b.Property("ToStdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("ToTopPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToUom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.HasKey("Id"); + + b.HasIndex("ToPackingCode"); + + b.HasIndex("FromPackingCode", "ToPackingCode"); + + b.ToTable("Store_SplitPackingRec", (string)null); + }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => { b.Property("Id") @@ -17763,6 +17917,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Priority") .ValueGeneratedOnAdd() .HasColumnType("int") @@ -17786,6 +17943,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedIssueType") + .HasColumnType("int"); + b.Property("UpStreamJobNumber") .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -17813,6 +17973,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("Id") .HasColumnType("uniqueidentifier"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("CreationTime") .HasColumnType("datetime2") .HasColumnName("CreationTime"); @@ -17821,6 +17984,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("CreatorId"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -17919,6 +18085,12 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("ReasonCode") .HasColumnType("nvarchar(max)"); @@ -18061,6 +18233,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -18074,6 +18249,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedIssueType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -18093,6 +18271,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -18109,6 +18290,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -18235,6 +18419,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -18244,6 +18431,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") @@ -18420,6 +18610,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -18434,6 +18627,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); + b.Property("UnplannedIssueType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -18453,6 +18649,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -18469,6 +18668,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -18538,6 +18740,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -18547,6 +18752,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") @@ -18683,6 +18891,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Priority") .ValueGeneratedOnAdd() .HasColumnType("int") @@ -18706,6 +18917,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedReceiptType") + .HasColumnType("int"); + b.Property("UpStreamJobNumber") .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -18733,6 +18947,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("Id") .HasColumnType("uniqueidentifier"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("CreationTime") .HasColumnType("datetime2") .HasColumnName("CreationTime"); @@ -18741,6 +18958,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("CreatorId"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -18839,6 +19059,12 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("ReasonCode") .HasColumnType("nvarchar(max)"); @@ -18981,6 +19207,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -18994,6 +19223,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedReceiptType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -19013,6 +19245,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -19029,6 +19264,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -19155,6 +19393,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -19164,6 +19405,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") @@ -19340,6 +19584,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -19354,6 +19601,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); + b.Property("UnplannedReceiptType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -19373,6 +19623,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -19389,6 +19642,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -19458,6 +19714,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -19467,11 +19726,17 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") .HasColumnName("Qty"); + b.Property("ReasonCode") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -19773,7 +20038,7 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); }); - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNote", b => { b.Property("Id") .HasColumnType("uniqueidentifier"); @@ -19787,6 +20052,12 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(40)") .HasColumnName("ConcurrencyStamp"); + b.Property("ConfirmTime") + .HasColumnType("datetime2"); + + b.Property("Confirmed") + .HasColumnType("bit"); + b.Property("CreationTime") .HasColumnType("datetime2") .HasColumnName("CreationTime"); @@ -19795,33 +20066,14 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("CreatorId"); - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") + b.Property("JobNumber") .HasMaxLength(64) .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); + .HasColumnName("JobNumber"); b.Property("LastModificationTime") .HasColumnType("datetime2") @@ -19831,36 +20083,589 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("LastModifierId"); - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - b.Property("Number") .IsRequired() .HasMaxLength(64) .HasColumnType("nvarchar(64)") .HasColumnName("Number"); - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") .HasColumnName("Remark"); + b.Property("RequestNumber") + .HasColumnType("nvarchar(max)"); + b.Property("TenantId") .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); b.Property("Type") - .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Worker") + .HasColumnType("nvarchar(max)"); + + b.HasKey("Id"); + + b.HasIndex("Number") + .IsUnique(); + + b.ToTable("Store_WipWarehouseAdjustNote", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNoteDetail", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ArriveDate") + .HasColumnType("datetime2"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("ExpireDate") + .HasColumnType("datetime2"); + + b.Property("FromContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("FromLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationArea"); + + b.Property("FromLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationCode"); + + b.Property("FromLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationErpCode"); + + b.Property("FromLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationGroup"); + + b.Property("FromLot") + .HasColumnType("nvarchar(max)"); + + b.Property("FromPackingCode") + .HasColumnType("nvarchar(450)"); + + b.Property("FromStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromWarehouseCode"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemCode"); + + b.Property("ItemDesc1") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc1"); + + b.Property("ItemDesc2") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc2"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemName"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("MasterID") + .HasColumnType("uniqueidentifier"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("ProduceDate") + .HasColumnType("datetime2"); + + b.Property("Qty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)") + .HasColumnName("Qty"); + + b.Property("Reason") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ReasonCode") + .HasMaxLength(4096) + .HasColumnType("nvarchar(max)"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("StdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("SupplierBatch") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("SupplierBatch"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("ToContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationArea"); + + b.Property("ToLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationCode"); + + b.Property("ToLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationErpCode"); + + b.Property("ToLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationGroup"); + + b.Property("ToLot") + .HasColumnType("nvarchar(max)"); + + b.Property("ToPackingCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToWarehouseCode"); + + b.Property("Uom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Uom"); + + b.HasKey("Id"); + + b.HasIndex("MasterID"); + + b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") + .IsUnique() + .HasFilter("[FromPackingCode] IS NOT NULL"); + + b.ToTable("Store_WipWarehouseAdjustNoteDetail", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequest", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ActiveDate") + .HasColumnType("datetime2"); + + b.Property("AutoAgree") + .HasColumnType("bit"); + + b.Property("AutoCompleteJob") + .HasColumnType("bit"); + + b.Property("AutoHandle") + .HasColumnType("bit"); + + b.Property("AutoSubmit") + .HasColumnType("bit"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasMaxLength(40) + .HasColumnType("nvarchar(40)") + .HasColumnName("ConcurrencyStamp"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("DirectCreateNote") + .HasColumnType("bit"); + + b.Property("ExtraProperties") + .HasColumnType("nvarchar(max)") + .HasColumnName("ExtraProperties"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("RequestStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("Type") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Worker") + .HasColumnType("nvarchar(max)"); + + b.HasKey("Id"); + + b.HasIndex("Number") + .IsUnique(); + + b.ToTable("Store_WipWarehouseAdjustRequest", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequestDetail", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ArriveDate") + .HasColumnType("datetime2"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("ExpireDate") + .HasColumnType("datetime2"); + + b.Property("FromContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("FromLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationArea"); + + b.Property("FromLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationCode"); + + b.Property("FromLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationErpCode"); + + b.Property("FromLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationGroup"); + + b.Property("FromLot") + .HasColumnType("nvarchar(max)"); + + b.Property("FromPackingCode") + .HasColumnType("nvarchar(max)"); + + b.Property("FromStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromWarehouseCode"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemCode"); + + b.Property("ItemDesc1") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc1"); + + b.Property("ItemDesc2") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc2"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemName"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("MasterID") + .HasColumnType("uniqueidentifier"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("ProduceDate") + .HasColumnType("datetime2"); + + b.Property("Qty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)") + .HasColumnName("Qty"); + + b.Property("Reason") + .HasMaxLength(4096) + .HasColumnType("nvarchar(max)"); + + b.Property("ReasonCode") + .HasMaxLength(4096) + .HasColumnType("nvarchar(max)"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("StdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("SupplierBatch") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("SupplierBatch"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("ToContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationArea"); + + b.Property("ToLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationCode"); + + b.Property("ToLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationErpCode"); + + b.Property("ToLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationGroup"); + + b.Property("ToLot") + .HasColumnType("nvarchar(max)"); + + b.Property("ToPackingCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToWarehouseCode"); + + b.Property("Uom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Uom"); + + b.HasKey("Id"); + + b.HasIndex("MasterID"); + + b.ToTable("Store_WipWarehouseAdjustRequestDetail", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ActiveDate") + .HasColumnType("datetime2"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasMaxLength(40) + .HasColumnType("nvarchar(40)") + .HasColumnName("ConcurrencyStamp"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("EffectiveDate") + .HasColumnType("datetime2"); + + b.Property("ExtraProperties") + .HasColumnType("nvarchar(max)") + .HasColumnName("ExtraProperties"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemCode"); + + b.Property("ItemDesc1") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc1"); + + b.Property("ItemDesc2") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc2"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemName"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("LocationCode") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("Op") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Qty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)") + .HasColumnName("Qty"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("Type") + .IsRequired() .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -20621,6 +21426,24 @@ namespace Win_in.Sfs.Wms.Store.Migrations .IsRequired(); }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNoteDetail", b => + { + b.HasOne("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNote", null) + .WithMany("Details") + .HasForeignKey("MasterID") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequestDetail", b => + { + b.HasOne("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequest", null) + .WithMany("Details") + .HasForeignKey("MasterID") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => { b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) @@ -20973,6 +21796,16 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Navigation("Details"); }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNote", b => + { + b.Navigation("Details"); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequest", b => + { + b.Navigation("Details"); + }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => { b.Navigation("Details"); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223055707_temp.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223055707_temp.cs new file mode 100644 index 000000000..058326ded --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223055707_temp.cs @@ -0,0 +1,8075 @@ +using System; +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace Win_in.Sfs.Wms.Store.Migrations +{ + public partial class temp : Migration + { + protected override void Up(MigrationBuilder migrationBuilder) + { + migrationBuilder.CreateTable( + name: "Job_CheckJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + DeliverNoteNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_CheckJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_CountJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CountPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CountStage = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CountMethod = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Description = table.Column(type: "nvarchar(max)", nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_CountJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_DeliverJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + DeliverRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CustomerAddressCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeliverTime = table.Column(type: "datetime2", nullable: false), + DeliverPlanNumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_DeliverJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_InspectJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + InspectNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(max)", nullable: true), + NextAction = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_InspectJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_IssueJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RequestType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + MaterialRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + UseOnTheWayLocation = table.Column(type: "bit", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_IssueJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_JisDeliverJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Customer = table.Column(type: "nvarchar(max)", nullable: true), + CustomerAddressCode = table.Column(type: "nvarchar(max)", nullable: true), + CustomerLocationCode = table.Column(type: "nvarchar(max)", nullable: true), + CustomerWarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), + ProjectCode = table.Column(type: "nvarchar(max)", nullable: true), + Position = table.Column(type: "nvarchar(max)", nullable: true), + PlanTime = table.Column(type: "datetime2", nullable: false), + ContainerQty = table.Column(type: "decimal(18,6)", nullable: false), + ItemQty = table.Column(type: "decimal(18,6)", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_JisDeliverJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_ProductionReturnJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ProductionReturnRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_ProductionReturnJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_ProductReceiveJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ProductionPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_ProductReceiveJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_PurchaseReceiptJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierAddress = table.Column(type: "nvarchar(max)", nullable: true), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + TimeWindow = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PlanArriveDate = table.Column(type: "datetime2", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_PurchaseReceiptJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_PurchaseReturnJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PurchaseReturnRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReturnReason = table.Column(type: "nvarchar(max)", nullable: true), + ReturnTime = table.Column(type: "datetime2", nullable: false), + ReturnType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_PurchaseReturnJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_PutawayJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PutawayMode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + InspectNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_PutawayJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_UnplannedIssueJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + UnplannedIssueRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + BuildDate = table.Column(type: "datetime2", nullable: false), + UnplannedIssueType = table.Column(type: "int", nullable: false), + OANumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_UnplannedIssueJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_UnplannedReceiptJob", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + UnplannedReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + BuildDate = table.Column(type: "datetime2", nullable: false), + UnplannedReceiptType = table.Column(type: "int", nullable: false), + OANumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UpStreamJobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobDescription = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + JobType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Priority = table.Column(type: "int", nullable: false, defaultValue: 0), + PriorityIncrement = table.Column(type: "int", nullable: false, defaultValue: 0), + WorkGroupCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsAutoComplete = table.Column(type: "bit", nullable: false, defaultValue: false), + AcceptUserId = table.Column(type: "uniqueidentifier", nullable: true), + AcceptUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AcceptTime = table.Column(type: "datetime2", nullable: true), + CompleteUserId = table.Column(type: "uniqueidentifier", nullable: true), + CompleteUserName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_UnplannedReceiptJob", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_BackFlushNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CompleteTime = table.Column(type: "datetime2", nullable: false), + Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductionPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ProductReceiptNumber = table.Column(type: "nvarchar(max)", nullable: true), + ProductRecycleNumber = table.Column(type: "nvarchar(max)", nullable: true), + JobNumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_BackFlushNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ContainerBindNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + BindType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + BindTime = table.Column(type: "datetime2", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ContainerBindNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_CountAdjustNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CountNoteNumber = table.Column(type: "nvarchar(max)", nullable: true), + CountPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CountAdjustRequestNumber = table.Column(type: "nvarchar(max)", nullable: true), + JobNumber = table.Column(type: "nvarchar(max)", nullable: true), + IsAdjusted = table.Column(type: "bit", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CountAdjustNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_CountAdjustRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CountNoteNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CountPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CountAdjustRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_CountNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CountPlanNumber = table.Column(type: "nvarchar(max)", nullable: true), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Stage = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Description = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + BeginTime = table.Column(type: "datetime2", nullable: false), + EndTime = table.Column(type: "datetime2", nullable: false), + Adjusted = table.Column(type: "bit", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CountNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_CountPlan", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Stage = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RequestType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CountMethod = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Description = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + BeginTime = table.Column(type: "datetime2", nullable: true), + EndTime = table.Column(type: "datetime2", nullable: true), + PlanTime = table.Column(type: "datetime2", nullable: false), + JsonItemCodes = table.Column(type: "nvarchar(max)", nullable: true), + JsonLocationCodes = table.Column(type: "nvarchar(max)", nullable: true), + JsonInventoryStatus = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CountPlan", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_CustomerAsn", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + SoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "int", nullable: false), + ContactName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ContactPhone = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ContactEmail = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DockCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + BeginTime = table.Column(type: "datetime2", nullable: true), + EndTime = table.Column(type: "datetime2", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CustomerAsn", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_CustomerReturnNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReturnTime = table.Column(type: "datetime2", nullable: false), + Customer = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CustomerReturnNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_DeliverNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CustomerAddressCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeliverPlanNumber = table.Column(type: "nvarchar(max)", nullable: true), + DeliverTime = table.Column(type: "datetime2", nullable: false), + DeliverRequestNumber = table.Column(type: "nvarchar(max)", nullable: true), + DeliverRequestType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CountPrint = table.Column(type: "int", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_DeliverNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_DeliverPlan", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PlanDate = table.Column(type: "datetime2", nullable: false), + PlanTime = table.Column(type: "datetime2", nullable: false), + CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CustomerAddressCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Project = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_DeliverPlan", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_DeliverRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + DeliverTime = table.Column(type: "datetime2", nullable: false), + DeliverPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CustomerAddressCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeliverRequestType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_DeliverRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ExchangeData", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Number = table.Column(type: "bigint", nullable: false), + DataType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + DataAction = table.Column(type: "int", nullable: false), + EffectiveDate = table.Column(type: "datetime2", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + DataIdentityCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + DataContent = table.Column(type: "nvarchar(max)", nullable: true), + DestinationSystem = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ReadTime = table.Column(type: "datetime2", nullable: true), + Reader = table.Column(type: "nvarchar(max)", nullable: true), + SourceSystem = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WriteTime = table.Column(type: "datetime2", nullable: false), + Writer = table.Column(type: "nvarchar(max)", nullable: true), + ErrorCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ErrorMessage = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + RetryTimes = table.Column(type: "int", nullable: false), + TyrpNumber = table.Column(type: "nvarchar(max)", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ExchangeData", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_InspectAbnormalNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + InspectNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InspectAbnormalNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_InspectNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + InspectNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + NextAction = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InspectNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_InspectRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InspectRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_InventoryInitialNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InventoryInitialNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_InventoryTransferNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + TransferType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InventoryTransferNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_IsolationNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_IsolationNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_IssueNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RequestType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + UseOnTheWayLocation = table.Column(type: "bit", nullable: false), + ConfirmTime = table.Column(type: "datetime2", nullable: true), + Confirmed = table.Column(type: "bit", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_IssueNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ItemTransformNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobNumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ItemTransformNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ItemTransformRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ItemTransformRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_JisDeliverNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Customer = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CustomerAddressCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ProjectCode = table.Column(type: "nvarchar(max)", nullable: true), + DeliverTime = table.Column(type: "datetime2", nullable: false), + ContainerQty = table.Column(type: "decimal(18,6)", nullable: false), + ItemQty = table.Column(type: "decimal(18,6)", nullable: false), + TotalPackCapacity = table.Column(type: "nvarchar(max)", nullable: true), + ArrivalTime = table.Column(type: "datetime2", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_JisDeliverNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_JisProductReceiptNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReceiptType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SourceNumber = table.Column(type: "nvarchar(max)", nullable: true), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductionPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(max)", nullable: true), + RawLocationCode = table.Column(type: "nvarchar(max)", nullable: true), + ProdLine = table.Column(type: "nvarchar(max)", nullable: true), + WorkShop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: false), + ContainerQty = table.Column(type: "decimal(18,6)", nullable: false), + ItemQty = table.Column(type: "decimal(18,6)", nullable: false), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_JisProductReceiptNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_MaterialRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PreparationPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + UseOnTheWayLocation = table.Column(type: "bit", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_MaterialRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_NoOkConvertOkNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_NoOkConvertOkNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_OfflineSettlementNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(max)", nullable: true), + ProductReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_OfflineSettlementNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_PreparationPlan", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ProductionPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Team = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PlanDate = table.Column(type: "datetime2", nullable: false), + PlanTime = table.Column(type: "datetime2", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PreparationPlan", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductionPlan", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Team = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + PlanDate = table.Column(type: "datetime2", nullable: false), + PlanTime = table.Column(type: "datetime2", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductionPlan", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductionReturnNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductionReturnRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReturnTime = table.Column(type: "datetime2", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductionReturnNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductionReturnRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductionReturnRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductL7PartsNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Year = table.Column(type: "nvarchar(max)", nullable: true), + ProductNo = table.Column(type: "nvarchar(max)", nullable: true), + Program = table.Column(type: "nvarchar(max)", nullable: true), + Position = table.Column(type: "nvarchar(max)", nullable: true), + FATA = table.Column(type: "nvarchar(max)", nullable: true), + Configuration = table.Column(type: "nvarchar(max)", nullable: true), + ContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + State = table.Column(type: "int", nullable: false), + CreateDate = table.Column(type: "datetime2", nullable: false), + Status = table.Column(type: "int", nullable: false), + ReceiptNumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductL7PartsNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductReceiptNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReceiptType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SourceNumber = table.Column(type: "nvarchar(max)", nullable: true), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductionPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + WorkShop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CompleteTime = table.Column(type: "datetime2", nullable: false), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductReceiptNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductReceiptRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ProductionPlanNumber = table.Column(type: "nvarchar(max)", nullable: true), + Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Team = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PlanDate = table.Column(type: "datetime2", nullable: false), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductReceiptRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductRecycleNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RequestNumber = table.Column(type: "nvarchar(max)", nullable: true), + RecycleTime = table.Column(type: "datetime2", nullable: false), + Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductRecycleNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductRecycleRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Workshop = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Shift = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductRecycleRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_PurchaseOrder", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierName = table.Column(type: "nvarchar(max)", nullable: true), + SupplierAddress = table.Column(type: "nvarchar(max)", nullable: true), + PoType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + OrderStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + IsConsignment = table.Column(type: "bit", nullable: false, defaultValue: false), + OrderDate = table.Column(type: "datetime2", nullable: false), + DueDate = table.Column(type: "datetime2", nullable: false), + Version = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + TaxRate = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + ContactName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ContactPhone = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ContactEmail = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PurchaseOrder", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_PurchaseReceiptNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierName = table.Column(type: "nvarchar(max)", nullable: true), + SupplierAddress = table.Column(type: "nvarchar(max)", nullable: true), + ReceiveTime = table.Column(type: "datetime2", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + WarehouseCode = table.Column(type: "nvarchar(max)", nullable: true), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PurchaseReceiptNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_PurchaseReceiptRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierAddress = table.Column(type: "nvarchar(max)", nullable: true), + TruckNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DockCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + TimeWindow = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + PlanArriveDate = table.Column(type: "datetime2", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PurchaseReceiptRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_PurchaseReturnNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PurchaseReturnRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReturnReason = table.Column(type: "nvarchar(max)", nullable: true), + ReturnTime = table.Column(type: "datetime2", nullable: false), + ReturnType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PurchaseReturnNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_PurchaseReturnRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReturnTime = table.Column(type: "datetime2", nullable: false), + ReturnType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PurchaseReturnRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_PutawayNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + InspectNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PutawayNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_PutawayRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PutawayMode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierCode = table.Column(type: "nvarchar(max)", nullable: true), + InspectNumber = table.Column(type: "nvarchar(max)", nullable: true), + ReceiptNumber = table.Column(type: "nvarchar(max)", nullable: true), + PurchaseReceiptRequestNumber = table.Column(type: "nvarchar(max)", nullable: true), + AsnNumber = table.Column(type: "nvarchar(max)", nullable: true), + RpNumber = table.Column(type: "nvarchar(max)", nullable: true), + PoNumber = table.Column(type: "nvarchar(max)", nullable: true), + ProductReceiptNumber = table.Column(type: "nvarchar(max)", nullable: true), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RequestNumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PutawayRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ReceiptAbnormalNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ReceiptAbnormalNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_RecycledMaterialReceiptNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_RecycledMaterialReceiptNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_SaleOrder", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CustomerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SoType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SoStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + OrderDate = table.Column(type: "datetime2", nullable: false), + DueDate = table.Column(type: "datetime2", nullable: false), + Version = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + TaxRate = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + ContactName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ContactPhone = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ContactEmail = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_SaleOrder", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ScrapNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ScrapRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ScrapNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_ScrapRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ScrapRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_SplitPackingRec", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + OprType = table.Column(type: "int", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromTopPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromUom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + ToPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToTopPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + ToUom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(1024)", maxLength: 1024, nullable: true), + FromLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PurchaseInfo_PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PurchaseInfo_AsnNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArrivalNoticNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + TaskOrderNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiptRecNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PutOnShelfNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LabelType = table.Column(type: "int", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(max)", nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_SplitPackingRec", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_SupplierAsn", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RpNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierName = table.Column(type: "nvarchar(max)", nullable: true), + SupplierAddress = table.Column(type: "nvarchar(max)", nullable: true), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContactName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ContactPhone = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ContactEmail = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + TruckNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DockCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ShipDate = table.Column(type: "datetime2", nullable: false), + DueDate = table.Column(type: "datetime2", nullable: false), + TimeWindow = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PlanArriveDate = table.Column(type: "datetime2", nullable: false), + Ctype = table.Column(type: "nvarchar(max)", nullable: true), + PlanUserCode = table.Column(type: "nvarchar(max)", nullable: true), + CreateType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_SupplierAsn", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_TransferNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RequestNumber = table.Column(type: "nvarchar(max)", nullable: true), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + UseOnTheWayLocation = table.Column(type: "bit", nullable: false), + ConfirmTime = table.Column(type: "datetime2", nullable: true), + Confirmed = table.Column(type: "bit", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_TransferNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_TransferRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + UseOnTheWayLocation = table.Column(type: "bit", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_TransferRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_UnplannedIssueNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + BuildDate = table.Column(type: "datetime2", nullable: false), + UnplannedIssueRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + UnplannedIssueType = table.Column(type: "int", nullable: false), + OANumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_UnplannedIssueNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_UnplannedIssueRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + BuildDate = table.Column(type: "datetime2", nullable: false), + UnplannedIssueType = table.Column(type: "int", nullable: false), + OANumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_UnplannedIssueRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_UnplannedReceiptNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + BuildDate = table.Column(type: "datetime2", nullable: false), + UnplannedReceiptRequestNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + UnplannedReceiptType = table.Column(type: "int", nullable: false), + OANumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_UnplannedReceiptNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_UnplannedReceiptRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + DeptCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DeptName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + BuildDate = table.Column(type: "datetime2", nullable: false), + UnplannedReceiptType = table.Column(type: "int", nullable: false), + OANumber = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_UnplannedReceiptRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_WarehouseTransferNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_WarehouseTransferNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_WipWarehouseAdjustNote", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RequestNumber = table.Column(type: "nvarchar(max)", nullable: true), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Confirmed = table.Column(type: "bit", nullable: false), + ConfirmTime = table.Column(type: "datetime2", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_WipWarehouseAdjustNote", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_WipWarehouseAdjustRequest", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false), + AutoSubmit = table.Column(type: "bit", nullable: false), + AutoAgree = table.Column(type: "bit", nullable: false), + AutoHandle = table.Column(type: "bit", nullable: false), + AutoCompleteJob = table.Column(type: "bit", nullable: false), + DirectCreateNote = table.Column(type: "bit", nullable: false), + RequestStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_WipWarehouseAdjustRequest", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Store_WorkOrder", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + WorkOrderId = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + EffectiveDate = table.Column(type: "datetime2", nullable: false), + WorkStation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + WoStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Op = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Type = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(40)", maxLength: 40, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + Worker = table.Column(type: "nvarchar(max)", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ActiveDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_WorkOrder", x => x.Id); + }); + + migrationBuilder.CreateTable( + name: "Job_CheckJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Order = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CustomerItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_CheckJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_CheckJobDetail_Job_CheckJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_CheckJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_CountJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CountLabel = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + InventoryQty = table.Column(type: "decimal(18,6)", nullable: false), + Uom = table.Column(type: "nvarchar(max)", nullable: true), + InventoryLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CountQty = table.Column(type: "decimal(18,6)", nullable: false), + CountTime = table.Column(type: "datetime2", nullable: true), + CountOperator = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CountDescription = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_CountJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_CountJobDetail_Job_CountJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_CountJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_DeliverJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationArea = table.Column(type: "nvarchar(max)", nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(max)", nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + OnTheWayLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(max)", nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_DeliverJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_DeliverJobDetail_Job_DeliverJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_DeliverJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_InspectJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + InspectType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SamplePercent = table.Column(type: "decimal(18,6)", nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiveQty = table.Column(type: "decimal(18,6)", nullable: false), + InspectQty = table.Column(type: "decimal(18,6)", nullable: false), + GoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + FailedReason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FailedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + CrackQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + InspectUser = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + NotPassedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + AbcClass = table.Column(type: "nvarchar(max)", nullable: true), + DetailInspectStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Appearance = table.Column(type: "nvarchar(max)", nullable: true), + Volume = table.Column(type: "nvarchar(max)", nullable: true), + Weight = table.Column(type: "nvarchar(max)", nullable: true), + OtherPropertyJson = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_InspectJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_InspectJobDetail_Job_InspectJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_InspectJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_InspectJobSummaryDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + InspectType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SamplePercent = table.Column(type: "decimal(18,6)", nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiveQty = table.Column(type: "decimal(18,6)", nullable: false), + InspectQty = table.Column(type: "decimal(18,6)", nullable: false), + GoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + FailedReason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FailedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + CrackQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + InspectUser = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + NotPassedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + SummaryInspectStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + AbcClass = table.Column(type: "nvarchar(max)", nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + InspectReport = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_InspectJobSummaryDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_InspectJobSummaryDetail_Job_InspectJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_InspectJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_IssueJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RequestLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + OnTheWayLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + WorkStation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExpiredTime = table.Column(type: "datetime2", nullable: false), + Operation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DistributionType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + TruncType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RoundedQty = table.Column(type: "decimal(18,6)", nullable: false), + PlannedSplitRule = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + PlanBeginTime = table.Column(type: "datetime2", nullable: false), + DeliveryQty = table.Column(type: "decimal(18,6)", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(max)", nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_IssueJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_IssueJobDetail_Job_IssueJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_IssueJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_JisDeliverJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ContainerName = table.Column(type: "nvarchar(max)", nullable: true), + ContainerDesc = table.Column(type: "nvarchar(max)", nullable: true), + ItemQty = table.Column(type: "decimal(18,6)", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Status = table.Column(type: "nvarchar(max)", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(max)", nullable: true), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_JisDeliverJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_JisDeliverJobDetail_Job_JisDeliverJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_JisDeliverJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_ProductionReturnJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(max)", nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_ProductionReturnJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_ProductionReturnJobDetail_Job_ProductionReturnJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_ProductionReturnJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_ProductReceiveJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RawLocationCode = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(max)", nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_ProductReceiveJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_ProductReceiveJobDetail_Job_ProductReceiveJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_ProductReceiveJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_PurchaseReceiptJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + PurchaseReceiptInspectStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + InspectPhotoJson = table.Column(type: "nvarchar(max)", nullable: true), + FailedReason = table.Column(type: "nvarchar(max)", nullable: true), + MassDefect = table.Column(type: "nvarchar(max)", nullable: true), + SupplierPackUom = table.Column(type: "nvarchar(max)", nullable: true), + SupplierPackQty = table.Column(type: "decimal(18,6)", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(max)", nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_PurchaseReceiptJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_PurchaseReceiptJobDetail_Job_PurchaseReceiptJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_PurchaseReceiptJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_PurchaseReturnJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Reason = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(max)", nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_PurchaseReturnJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_PurchaseReturnJobDetail_Job_PurchaseReturnJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_PurchaseReturnJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_PutawayJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_PutawayJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_PutawayJobDetail_Job_PutawayJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_PutawayJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_UnplannedIssueJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), + CaseCode = table.Column(type: "nvarchar(max)", nullable: true), + ProjCapacityCode = table.Column(type: "nvarchar(max)", nullable: true), + OnceBusiCode = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + Explain = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(max)", nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_UnplannedIssueJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_UnplannedIssueJobDetail_Job_UnplannedIssueJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_UnplannedIssueJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Job_UnplannedReceiptJobDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), + CaseCode = table.Column(type: "nvarchar(max)", nullable: true), + ProjCapacityCode = table.Column(type: "nvarchar(max)", nullable: true), + OnceBusiCode = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + Explain = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(max)", nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Job_UnplannedReceiptJobDetail", x => x.Id); + table.ForeignKey( + name: "FK_Job_UnplannedReceiptJobDetail_Job_UnplannedReceiptJob_MasterID", + column: x => x.MasterID, + principalTable: "Job_UnplannedReceiptJob", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_BackFlushNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + IsOffLine = table.Column(type: "bit", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_BackFlushNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_BackFlushNoteDetail_Store_BackFlushNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_BackFlushNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ContainerBindNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ContainerBindNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ContainerBindNoteDetail_Store_ContainerBindNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_ContainerBindNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_CountAdjustNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CountLabel = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + InventoryQty = table.Column(type: "decimal(18,6)", nullable: false), + TransInOut = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ReasonCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CountQty = table.Column(type: "decimal(18,6)", nullable: false), + AdjustQty = table.Column(type: "decimal(18,6)", nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CountAdjustNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_CountAdjustNoteDetail_Store_CountAdjustNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_CountAdjustNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_CountAdjustRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), + InventoryQty = table.Column(type: "decimal(18,6)", nullable: false), + CountQty = table.Column(type: "decimal(18,6)", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CountAdjustRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_CountAdjustRequestDetail_Store_CountAdjustRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_CountAdjustRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_CountNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CountPlanNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CountLabel = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(max)", nullable: true), + InventoryQty = table.Column(type: "decimal(18,6)", nullable: false), + FirstCountQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + FirstCountTime = table.Column(type: "datetime2", nullable: true), + FirstCountOperator = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FirstCountDescription = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RepeatCountQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + RepeatCountTime = table.Column(type: "datetime2", nullable: true), + RepeatCountOperator = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RepeatCountDescription = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AuditCountQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + AuditCountTime = table.Column(type: "datetime2", nullable: true), + AuditCountOperator = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AuditCountDescription = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FinalCountQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + DetailStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Stage = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Adjusted = table.Column(type: "bit", nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CountNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_CountNoteDetail_Store_CountNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_CountNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_CountPlanDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CountLabel = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + InventoryQty = table.Column(type: "decimal(18,6)", nullable: false), + FirstCountQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + FirstCountTime = table.Column(type: "datetime2", nullable: true), + FirstCountOperator = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FirstCountDescription = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RepeatCountQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + RepeatCountTime = table.Column(type: "datetime2", nullable: true), + RepeatCountOperator = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RepeatCountDescription = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AuditCountQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + AuditCountTime = table.Column(type: "datetime2", nullable: true), + AuditCountOperator = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + AuditCountDescription = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + DetailStatus = table.Column(type: "int", nullable: false), + Stage = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FinalCountQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CountPlanDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_CountPlanDetail_Store_CountPlan_MasterID", + column: x => x.MasterID, + principalTable: "Store_CountPlan", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_CustomerAsnDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + SoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CustomerAsnDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_CustomerAsnDetail_Store_CustomerAsn_MasterID", + column: x => x.MasterID, + principalTable: "Store_CustomerAsn", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_CustomerReturnNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_CustomerReturnNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_CustomerReturnNoteDetail_Store_CustomerReturnNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_CustomerReturnNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_DeliverNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_DeliverNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_DeliverNoteDetail_Store_DeliverNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_DeliverNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_DeliverPlanDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + SoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_DeliverPlanDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_DeliverPlanDetail_Store_DeliverPlan_MasterID", + column: x => x.MasterID, + principalTable: "Store_DeliverPlan", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_DeliverRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + AreaCode = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_DeliverRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_DeliverRequestDetail_Store_DeliverRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_DeliverRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_InspectAbnormalNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + AbnormalType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Photos = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InspectAbnormalNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_InspectAbnormalNoteDetail_Store_InspectAbnormalNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_InspectAbnormalNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_InspectNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + InspectType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SamplePercent = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiveQty = table.Column(type: "decimal(18,6)", nullable: false), + InspectQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + GoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + FailedReason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FailedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + CrackQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + Photos = table.Column(type: "nvarchar(max)", nullable: true), + InspectUser = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + NotPassedQty = table.Column(type: "decimal(18,6)", nullable: false), + DetailInspectStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + AbcClass = table.Column(type: "nvarchar(max)", nullable: true), + Appearance = table.Column(type: "nvarchar(max)", nullable: true), + Volume = table.Column(type: "nvarchar(max)", nullable: true), + Weight = table.Column(type: "nvarchar(max)", nullable: true), + OtherPropertyJson = table.Column(type: "nvarchar(max)", nullable: true), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + InspectDate = table.Column(type: "datetime2", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InspectNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_InspectNoteDetail_Store_InspectNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_InspectNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_InspectNoteSummaryDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + InspectType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SamplePercent = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiveQty = table.Column(type: "decimal(18,6)", nullable: false), + InspectQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + GoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + FailedReason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FailedQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + CrackQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + InspectUser = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + NotPassedQty = table.Column(type: "decimal(18,6)", nullable: false), + SummaryInspectStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + AbcClass = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InspectNoteSummaryDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_InspectNoteSummaryDetail_Store_InspectNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_InspectNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_InspectRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + InspectType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SamplePercent = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiveQty = table.Column(type: "decimal(18,6)", nullable: false), + InspectQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + Attributes = table.Column(type: "nvarchar(max)", nullable: true), + DetailInspectStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + AbcClass = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InspectRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_InspectRequestDetail_Store_InspectRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_InspectRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_InspectRequestSummaryDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + InspectType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + SamplePercent = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReceiveQty = table.Column(type: "decimal(18,6)", nullable: false), + InspectQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + InspectReport = table.Column(type: "nvarchar(max)", nullable: true), + SummaryInspectStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + GoodQty = table.Column(type: "decimal(18,6)", nullable: false), + FailedQty = table.Column(type: "decimal(18,6)", nullable: false), + CrackQty = table.Column(type: "decimal(18,6)", nullable: false), + NotPassedQty = table.Column(type: "decimal(18,6)", nullable: false), + AbcClass = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InspectRequestSummaryDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_InspectRequestSummaryDetail_Store_InspectRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_InspectRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_InventoryInitialNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InventoryInitialNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_InventoryInitialNoteDetail_Store_InventoryInitialNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_InventoryInitialNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_InventoryTransferNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Reason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_InventoryTransferNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_InventoryTransferNoteDetail_Store_InventoryTransferNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_InventoryTransferNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_IsolationNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_IsolationNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_IsolationNoteDetail_Store_IsolationNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_IsolationNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_IssueNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + IssueTime = table.Column(type: "datetime2", nullable: false), + ExpiredTime = table.Column(type: "datetime2", nullable: false), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + WorkStation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + OnTheWayLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_IssueNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_IssueNoteDetail_Store_IssueNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_IssueNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ItemTransformNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + FromQty = table.Column(type: "decimal(18,6)", nullable: false), + FromSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromArriveDate = table.Column(type: "datetime2", nullable: false), + FromProduceDate = table.Column(type: "datetime2", nullable: false), + FromExpireDate = table.Column(type: "datetime2", nullable: false), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToQty = table.Column(type: "decimal(18,6)", nullable: false), + ToSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToArriveDate = table.Column(type: "datetime2", nullable: false), + ToProduceDate = table.Column(type: "datetime2", nullable: false), + ToExpireDate = table.Column(type: "datetime2", nullable: false), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), + ConcurrencyStamp = table.Column(type: "nvarchar(max)", nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ItemTransformNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ItemTransformNoteDetail_Store_ItemTransformNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_ItemTransformNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ItemTransformRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + FromQty = table.Column(type: "decimal(18,6)", nullable: false), + FromSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromArriveDate = table.Column(type: "datetime2", nullable: false), + FromProduceDate = table.Column(type: "datetime2", nullable: false), + FromExpireDate = table.Column(type: "datetime2", nullable: false), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToArriveDate = table.Column(type: "datetime2", nullable: false), + ToProduceDate = table.Column(type: "datetime2", nullable: false), + ToExpireDate = table.Column(type: "datetime2", nullable: false), + ToQty = table.Column(type: "decimal(18,6)", nullable: false), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ItemTransformRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ItemTransformRequestDetail_Store_ItemTransformRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_ItemTransformRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_JisDeliverNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + DeliverTime = table.Column(type: "datetime2", nullable: false), + ExpiredTime = table.Column(type: "datetime2", nullable: false), + Year = table.Column(type: "nvarchar(max)", nullable: true), + ProductNo = table.Column(type: "nvarchar(max)", nullable: true), + ProjectCode = table.Column(type: "nvarchar(max)", nullable: true), + Position = table.Column(type: "nvarchar(max)", nullable: true), + SeqNo = table.Column(type: "nvarchar(max)", nullable: true), + PackCapacity = table.Column(type: "nvarchar(max)", nullable: true), + OnlineType = table.Column(type: "nvarchar(max)", nullable: true), + Stage = table.Column(type: "nvarchar(max)", nullable: true), + UsedFor = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_JisDeliverNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_JisDeliverNoteDetail_Store_JisDeliverNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_JisDeliverNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_JisProductReceiptNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RawLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Year = table.Column(type: "nvarchar(max)", nullable: true), + ProductNo = table.Column(type: "nvarchar(max)", nullable: true), + ProjectCode = table.Column(type: "nvarchar(max)", nullable: true), + Position = table.Column(type: "nvarchar(max)", nullable: true), + SeqNo = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_JisProductReceiptNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_JisProductReceiptNoteDetail_Store_JisProductReceiptNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_JisProductReceiptNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_MaterialRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(max)", nullable: true), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + WorkStation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExpiredTime = table.Column(type: "datetime2", nullable: false), + IssuedQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + ReceivedQty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_MaterialRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_MaterialRequestDetail_Store_MaterialRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_MaterialRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_NoOkConvertOkNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_NoOkConvertOkNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_NoOkConvertOkNoteDetail_Store_NoOkConvertOkNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_NoOkConvertOkNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_OfflineSettlementNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_OfflineSettlementNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_OfflineSettlementNoteDetail_Store_OfflineSettlementNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_OfflineSettlementNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_PreparationPlanDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WorkStation = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LineStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LatestTime = table.Column(type: "datetime2", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PreparationPlanDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_PreparationPlanDetail_Store_PreparationPlan_MasterID", + column: x => x.MasterID, + principalTable: "Store_PreparationPlan", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductionPlanDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PlanQty = table.Column(type: "decimal(18,6)", nullable: false), + GoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 1m), + NoGoodQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 1m), + BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LineStatus = table.Column(type: "int", nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductionPlanDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ProductionPlanDetail_Store_ProductionPlan_MasterID", + column: x => x.MasterID, + principalTable: "Store_ProductionPlan", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductionReturnNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductionReturnNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ProductionReturnNoteDetail_Store_ProductionReturnNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_ProductionReturnNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductionReturnRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductionReturnRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ProductionReturnRequestDetail_Store_ProductionReturnRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_ProductionReturnRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductL7PartsNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RowID = table.Column(type: "int", nullable: false), + ProductNo = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Program = table.Column(type: "nvarchar(max)", nullable: true), + Position = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FATA = table.Column(type: "nvarchar(max)", nullable: true), + Configuration = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + L7Part = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CanMake = table.Column(type: "bit", nullable: false), + CanBuy = table.Column(type: "bit", nullable: false), + RawLocationCode = table.Column(type: "nvarchar(max)", nullable: true), + LocationCode = table.Column(type: "nvarchar(max)", nullable: true), + ProdLine = table.Column(type: "nvarchar(max)", nullable: true), + Qty = table.Column(type: "int", nullable: false), + State = table.Column(type: "int", nullable: false), + CreateDate = table.Column(type: "datetime2", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductL7PartsNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ProductL7PartsNoteDetail_Store_ProductL7PartsNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_ProductL7PartsNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductReceiptNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RawLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RawArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProdLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReturnQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductReceiptNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ProductReceiptNoteDetail_Store_ProductReceiptNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_ProductReceiptNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductReceiptRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + RawArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ReturnQty = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 0m), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductReceiptRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ProductReceiptRequestDetail_Store_ProductReceiptRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_ProductReceiptRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductRecycleMaterialDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProductLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductRecycleMaterialDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ProductRecycleMaterialDetail_Store_ProductRecycleNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_ProductRecycleNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductRecycleNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReasonCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductRecycleNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ProductRecycleNoteDetail_Store_ProductRecycleNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_ProductRecycleNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ProductRecycleRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + BomVersion = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RawLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RawLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RawLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RawLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RawWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ProductRecycleRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ProductRecycleRequestDetail_Store_ProductRecycleRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_ProductRecycleRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_PurchaseOrderDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierPackUom = table.Column(type: "nvarchar(max)", nullable: true), + SupplierPackQty = table.Column(type: "decimal(18,6)", nullable: false), + ConvertRate = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 1m), + IsConsignment = table.Column(type: "bit", nullable: false, defaultValue: false), + LineStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ProjectCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ShippedQty = table.Column(type: "decimal(18,6)", nullable: false), + ReceivedQty = table.Column(type: "decimal(18,6)", nullable: false), + ReturnedQty = table.Column(type: "decimal(18,6)", nullable: false), + PutAwayQty = table.Column(type: "decimal(18,6)", nullable: false), + PlanUserCode = table.Column(type: "nvarchar(max)", nullable: true), + Lot = table.Column(type: "nvarchar(max)", nullable: true), + PlanArriveDate = table.Column(type: "datetime2", nullable: false), + Ctype = table.Column(type: "nvarchar(max)", nullable: true), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + OrderRemark = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PurchaseOrderDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_PurchaseOrderDetail_Store_PurchaseOrder_MasterID", + column: x => x.MasterID, + principalTable: "Store_PurchaseOrder", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_PurchaseReceiptNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PurchaseReceiptInspectStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + InspectPhotoJson = table.Column(type: "nvarchar(max)", nullable: true), + FailedReason = table.Column(type: "nvarchar(max)", nullable: true), + MassDefect = table.Column(type: "nvarchar(max)", nullable: true), + SupplierPackUom = table.Column(type: "nvarchar(max)", nullable: true), + SupplierPackQty = table.Column(type: "decimal(18,6)", nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PurchaseReceiptNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_PurchaseReceiptNoteDetail_Store_PurchaseReceiptNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_PurchaseReceiptNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_PurchaseReceiptRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierPackUom = table.Column(type: "nvarchar(max)", nullable: true), + SupplierPackQty = table.Column(type: "decimal(18,6)", nullable: false), + ConvertRate = table.Column(type: "decimal(18,6)", nullable: false), + RecommendErpCode = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PurchaseReceiptRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_PurchaseReceiptRequestDetail_Store_PurchaseReceiptRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_PurchaseReceiptRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_PurchaseReturnNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Reason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PurchaseReturnNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_PurchaseReturnNoteDetail_Store_PurchaseReturnNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_PurchaseReturnNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_PurchaseReturnRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PurchaseReturnRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_PurchaseReturnRequestDetail_Store_PurchaseReturnRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_PurchaseReturnRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_PutawayNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + JobNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PutawayNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_PutawayNoteDetail_Store_PutawayNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_PutawayNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_PutawayRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + InventoryQty = table.Column(type: "decimal(18,6)", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_PutawayRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_PutawayRequestDetail_Store_PutawayRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_PutawayRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ReceiptAbnormalNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReceiptNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + AbnormalType = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Photos = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ReceiptAbnormalNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ReceiptAbnormalNoteDetail_Store_ReceiptAbnormalNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_ReceiptAbnormalNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_RecycledMaterialReceiptNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_RecycledMaterialReceiptNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_RecycledMaterialReceiptNoteDetail_Store_RecycledMaterialReceiptNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_RecycledMaterialReceiptNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_SaleOrderDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + SoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CustomerPackUom = table.Column(type: "nvarchar(max)", nullable: true), + CustomerPackQty = table.Column(type: "decimal(18,6)", nullable: false), + ConvertRate = table.Column(type: "decimal(18,6)", nullable: false, defaultValue: 1m), + LineStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_SaleOrderDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_SaleOrderDetail_Store_SaleOrder_MasterID", + column: x => x.MasterID, + principalTable: "Store_SaleOrder", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ScrapNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReasonCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(450)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ScrapNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ScrapNoteDetail_Store_ScrapNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_ScrapNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_ScrapRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReasonCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_ScrapRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_ScrapRequestDetail_Store_ScrapRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_ScrapRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_SupplierAsnDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + PoNumber = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + PoLine = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierPackUom = table.Column(type: "nvarchar(max)", nullable: true), + SupplierPackQty = table.Column(type: "decimal(18,6)", nullable: false), + ConvertRate = table.Column(type: "decimal(18,6)", nullable: false), + ProjectCode = table.Column(type: "nvarchar(max)", nullable: true), + Ctype = table.Column(type: "nvarchar(max)", nullable: true), + RecommendErpCode = table.Column(type: "nvarchar(max)", nullable: true), + PlanUserCode = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_SupplierAsnDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_SupplierAsnDetail_Store_SupplierAsn_MasterID", + column: x => x.MasterID, + principalTable: "Store_SupplierAsn", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_TransferNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + OnTheWayLocationCode = table.Column(type: "nvarchar(max)", nullable: true), + Reason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_TransferNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_TransferNoteDetail_Store_TransferNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_TransferNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_TransferRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Reason = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_TransferRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_TransferRequestDetail_Store_TransferRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_TransferRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_UnplannedIssueNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), + CaseCode = table.Column(type: "nvarchar(max)", nullable: true), + ProjCapacityCode = table.Column(type: "nvarchar(max)", nullable: true), + OnceBusiCode = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + Explain = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledFromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_UnplannedIssueNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_UnplannedIssueNoteDetail_Store_UnplannedIssueNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_UnplannedIssueNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_UnplannedIssueRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + CaseCode = table.Column(type: "nvarchar(max)", nullable: true), + ProjCapacityCode = table.Column(type: "nvarchar(max)", nullable: true), + OnceBusiCode = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + Explain = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_UnplannedIssueRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_UnplannedIssueRequestDetail_Store_UnplannedIssueRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_UnplannedIssueRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_UnplannedReceiptNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), + CaseCode = table.Column(type: "nvarchar(max)", nullable: true), + ProjCapacityCode = table.Column(type: "nvarchar(max)", nullable: true), + OnceBusiCode = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + Explain = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + RecommendContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendArriveDate = table.Column(type: "datetime2", nullable: false), + RecommendProduceDate = table.Column(type: "datetime2", nullable: false), + RecommendExpireDate = table.Column(type: "datetime2", nullable: false), + RecommendLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RecommendQty = table.Column(type: "decimal(18,6)", nullable: false), + HandledContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledPackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledSupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledArriveDate = table.Column(type: "datetime2", nullable: false), + HandledProduceDate = table.Column(type: "datetime2", nullable: false), + HandledExpireDate = table.Column(type: "datetime2", nullable: false), + HandledLot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + HandledQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_UnplannedReceiptNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_UnplannedReceiptNoteDetail_Store_UnplannedReceiptNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_UnplannedReceiptNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_UnplannedReceiptRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + ReasonCode = table.Column(type: "nvarchar(max)", nullable: true), + CaseCode = table.Column(type: "nvarchar(max)", nullable: true), + ProjCapacityCode = table.Column(type: "nvarchar(max)", nullable: true), + OnceBusiCode = table.Column(type: "nvarchar(max)", nullable: true), + ExtraProperties = table.Column(type: "nvarchar(max)", nullable: true), + Explain = table.Column(type: "nvarchar(max)", nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Lot = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + PackingCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ContainerCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + LocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + LocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + WarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Status = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_UnplannedReceiptRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_UnplannedReceiptRequestDetail_Store_UnplannedReceiptRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_UnplannedReceiptRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_WarehouseTransferNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Reason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_WarehouseTransferNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_WarehouseTransferNoteDetail_Store_WarehouseTransferNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_WarehouseTransferNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_WipWarehouseAdjustNoteDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Reason = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ReasonCode = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(450)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_WipWarehouseAdjustNoteDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_WipWarehouseAdjustNoteDetail_Store_WipWarehouseAdjustNote_MasterID", + column: x => x.MasterID, + principalTable: "Store_WipWarehouseAdjustNote", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_WipWarehouseAdjustRequestDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + Reason = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), + ReasonCode = table.Column(type: "nvarchar(max)", maxLength: 4096, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Uom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Qty = table.Column(type: "decimal(18,6)", precision: 18, scale: 6, nullable: false), + StdPackQty = table.Column(type: "decimal(18,6)", nullable: false), + FromPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + ToPackingCode = table.Column(type: "nvarchar(max)", nullable: true), + FromContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + ToContainerCode = table.Column(type: "nvarchar(max)", nullable: true), + FromLot = table.Column(type: "nvarchar(max)", nullable: true), + ToLot = table.Column(type: "nvarchar(max)", nullable: true), + SupplierBatch = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ArriveDate = table.Column(type: "datetime2", nullable: false), + ProduceDate = table.Column(type: "datetime2", nullable: false), + ExpireDate = table.Column(type: "datetime2", nullable: false), + FromLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + FromLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + FromStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToLocationArea = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationGroup = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ToLocationErpCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToWarehouseCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + ToStatus = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_WipWarehouseAdjustRequestDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_WipWarehouseAdjustRequestDetail_Store_WipWarehouseAdjustRequest_MasterID", + column: x => x.MasterID, + principalTable: "Store_WipWarehouseAdjustRequest", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateTable( + name: "Store_WorkOrderDetail", + columns: table => new + { + Id = table.Column(type: "uniqueidentifier", nullable: false), + EffectiveDate = table.Column(type: "datetime2", nullable: false), + Op = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RawUom = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + RawQty = table.Column(type: "decimal(18,6)", nullable: false), + RawLocationCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + CreationTime = table.Column(type: "datetime2", nullable: false), + CreatorId = table.Column(type: "uniqueidentifier", nullable: true), + LastModificationTime = table.Column(type: "datetime2", nullable: true), + LastModifierId = table.Column(type: "uniqueidentifier", nullable: true), + MasterID = table.Column(type: "uniqueidentifier", nullable: false), + TenantId = table.Column(type: "uniqueidentifier", nullable: true), + Number = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false), + Remark = table.Column(type: "nvarchar(3072)", maxLength: 3072, nullable: true), + ItemName = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc1 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemDesc2 = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: true), + ItemCode = table.Column(type: "nvarchar(64)", maxLength: 64, nullable: false) + }, + constraints: table => + { + table.PrimaryKey("PK_Store_WorkOrderDetail", x => x.Id); + table.ForeignKey( + name: "FK_Store_WorkOrderDetail_Store_WorkOrder_MasterID", + column: x => x.MasterID, + principalTable: "Store_WorkOrder", + principalColumn: "Id", + onDelete: ReferentialAction.Cascade); + }); + + migrationBuilder.CreateIndex( + name: "IX_Job_CheckJob_Number", + table: "Job_CheckJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_CheckJobDetail_MasterID", + table: "Job_CheckJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_CountJob_Number", + table: "Job_CountJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_CountJobDetail_MasterID", + table: "Job_CountJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_DeliverJob_Number", + table: "Job_DeliverJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_DeliverJobDetail_MasterID", + table: "Job_DeliverJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_InspectJob_Number", + table: "Job_InspectJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_InspectJobDetail_MasterID", + table: "Job_InspectJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_InspectJobSummaryDetail_MasterID", + table: "Job_InspectJobSummaryDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_IssueJob_Number", + table: "Job_IssueJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_IssueJobDetail_MasterID", + table: "Job_IssueJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_JisDeliverJob_Number", + table: "Job_JisDeliverJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_JisDeliverJobDetail_MasterID", + table: "Job_JisDeliverJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_ProductionReturnJob_Number", + table: "Job_ProductionReturnJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_ProductionReturnJobDetail_MasterID", + table: "Job_ProductionReturnJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_ProductReceiveJob_Number", + table: "Job_ProductReceiveJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_ProductReceiveJobDetail_MasterID", + table: "Job_ProductReceiveJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_PurchaseReceiptJob_Number", + table: "Job_PurchaseReceiptJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_PurchaseReceiptJobDetail_MasterID", + table: "Job_PurchaseReceiptJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_PurchaseReturnJob_Number", + table: "Job_PurchaseReturnJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_PurchaseReturnJobDetail_MasterID", + table: "Job_PurchaseReturnJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_PutawayJob_Number", + table: "Job_PutawayJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_PutawayJobDetail_MasterID", + table: "Job_PutawayJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_UnplannedIssueJob_Number", + table: "Job_UnplannedIssueJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_UnplannedIssueJobDetail_MasterID", + table: "Job_UnplannedIssueJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Job_UnplannedReceiptJob_Number", + table: "Job_UnplannedReceiptJob", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Job_UnplannedReceiptJobDetail_MasterID", + table: "Job_UnplannedReceiptJobDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_BackFlushNote_Number", + table: "Store_BackFlushNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_BackFlushNoteDetail_MasterID", + table: "Store_BackFlushNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_BackFlushNoteDetail_Number_ItemCode_Lot", + table: "Store_BackFlushNoteDetail", + columns: new[] { "Number", "ItemCode", "Lot" }, + unique: true, + filter: "[Lot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ContainerBindNote_Number", + table: "Store_ContainerBindNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ContainerBindNoteDetail_MasterID", + table: "Store_ContainerBindNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ContainerBindNoteDetail_Number_PackingCode", + table: "Store_ContainerBindNoteDetail", + columns: new[] { "Number", "PackingCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountAdjustNote_Number", + table: "Store_CountAdjustNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountAdjustNoteDetail_MasterID", + table: "Store_CountAdjustNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountAdjustNoteDetail_Number_CountLabel_ItemCode_LocationCode_Lot_Status_PackingCode", + table: "Store_CountAdjustNoteDetail", + columns: new[] { "Number", "CountLabel", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode" }, + unique: true, + filter: "[Lot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountAdjustRequest_Number", + table: "Store_CountAdjustRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountAdjustRequestDetail_MasterID", + table: "Store_CountAdjustRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountAdjustRequestDetail_Number_ItemCode_LocationCode_Lot_Status_PackingCode", + table: "Store_CountAdjustRequestDetail", + columns: new[] { "Number", "ItemCode", "LocationCode", "Lot", "Status", "PackingCode" }, + unique: true, + filter: "[Lot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountNote_Number", + table: "Store_CountNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountNoteDetail_MasterID", + table: "Store_CountNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountNoteDetail_Number_CountLabel", + table: "Store_CountNoteDetail", + columns: new[] { "Number", "CountLabel" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountPlan_Number", + table: "Store_CountPlan", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountPlanDetail_MasterID", + table: "Store_CountPlanDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_CountPlanDetail_Number_CountLabel", + table: "Store_CountPlanDetail", + columns: new[] { "Number", "CountLabel" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_CustomerAsn_CustomerCode", + table: "Store_CustomerAsn", + column: "CustomerCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_CustomerAsn_Number", + table: "Store_CustomerAsn", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_CustomerAsnDetail_MasterID", + table: "Store_CustomerAsnDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_CustomerAsnDetail_Number_ItemCode", + table: "Store_CustomerAsnDetail", + columns: new[] { "Number", "ItemCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_CustomerReturnNote_Number", + table: "Store_CustomerReturnNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_CustomerReturnNoteDetail_MasterID", + table: "Store_CustomerReturnNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_CustomerReturnNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", + table: "Store_CustomerReturnNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_DeliverNote_Number", + table: "Store_DeliverNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_DeliverNoteDetail_MasterID", + table: "Store_DeliverNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_DeliverNoteDetail_Number_ItemCode_FromPackingCode_FromLot_FromLocationCode_ToLocationCode", + table: "Store_DeliverNoteDetail", + columns: new[] { "Number", "ItemCode", "FromPackingCode", "FromLot", "FromLocationCode", "ToLocationCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_DeliverPlan_Number", + table: "Store_DeliverPlan", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_DeliverPlanDetail_MasterID", + table: "Store_DeliverPlanDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_DeliverPlanDetail_Number_SoNumber_SoLine", + table: "Store_DeliverPlanDetail", + columns: new[] { "Number", "SoNumber", "SoLine" }, + unique: true, + filter: "[SoNumber] IS NOT NULL AND [SoLine] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_DeliverRequest_Number", + table: "Store_DeliverRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_DeliverRequestDetail_MasterID", + table: "Store_DeliverRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_DeliverRequestDetail_Number_ItemCode", + table: "Store_DeliverRequestDetail", + columns: new[] { "Number", "ItemCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectAbnormalNote_Number", + table: "Store_InspectAbnormalNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectAbnormalNoteDetail_MasterID", + table: "Store_InspectAbnormalNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectAbnormalNoteDetail_Number_PackingCode", + table: "Store_InspectAbnormalNoteDetail", + columns: new[] { "Number", "PackingCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectNote_Number", + table: "Store_InspectNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectNoteDetail_MasterID", + table: "Store_InspectNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectNoteDetail_Number_PackingCode", + table: "Store_InspectNoteDetail", + columns: new[] { "Number", "PackingCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectNoteSummaryDetail_MasterID", + table: "Store_InspectNoteSummaryDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectNoteSummaryDetail_Number_ItemCode", + table: "Store_InspectNoteSummaryDetail", + columns: new[] { "Number", "ItemCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectRequest_Number", + table: "Store_InspectRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectRequestDetail_MasterID", + table: "Store_InspectRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectRequestDetail_Number_PackingCode", + table: "Store_InspectRequestDetail", + columns: new[] { "Number", "PackingCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectRequestSummaryDetail_MasterID", + table: "Store_InspectRequestSummaryDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_InspectRequestSummaryDetail_Number_ItemCode_Lot", + table: "Store_InspectRequestSummaryDetail", + columns: new[] { "Number", "ItemCode", "Lot" }, + unique: true, + filter: "[Lot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_InventoryInitialNote_Number", + table: "Store_InventoryInitialNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_InventoryInitialNoteDetail_MasterID", + table: "Store_InventoryInitialNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_InventoryInitialNoteDetail_Number_PackingCode_ItemCode_Lot_Status", + table: "Store_InventoryInitialNoteDetail", + columns: new[] { "Number", "PackingCode", "ItemCode", "Lot", "Status" }, + unique: true, + filter: "[Lot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_InventoryTransferNote_Number", + table: "Store_InventoryTransferNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_InventoryTransferNoteDetail_MasterID", + table: "Store_InventoryTransferNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_InventoryTransferNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", + table: "Store_InventoryTransferNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_IsolationNote_Number", + table: "Store_IsolationNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_IsolationNoteDetail_FromPackingCode", + table: "Store_IsolationNoteDetail", + column: "FromPackingCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_IsolationNoteDetail_MasterID", + table: "Store_IsolationNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_IsolationNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", + table: "Store_IsolationNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_IssueNote_Number", + table: "Store_IssueNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_IssueNoteDetail_FromPackingCode", + table: "Store_IssueNoteDetail", + column: "FromPackingCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_IssueNoteDetail_MasterID", + table: "Store_IssueNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_IssueNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", + table: "Store_IssueNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ItemTransformNote_Number", + table: "Store_ItemTransformNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ItemTransformNoteDetail_MasterID", + table: "Store_ItemTransformNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ItemTransformNoteDetail_Number_FromPackingCode_FromStatus_ToPackingCode_ToStatus", + table: "Store_ItemTransformNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ItemTransformRequest_Number", + table: "Store_ItemTransformRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ItemTransformRequestDetail_MasterID", + table: "Store_ItemTransformRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ItemTransformRequestDetail_Number_FromPackingCode_FromStatus_ToPackingCode_ToStatus", + table: "Store_ItemTransformRequestDetail", + columns: new[] { "Number", "FromPackingCode", "FromStatus", "ToPackingCode", "ToStatus" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_JisDeliverNote_Number", + table: "Store_JisDeliverNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_JisDeliverNoteDetail_MasterID", + table: "Store_JisDeliverNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_JisDeliverNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", + table: "Store_JisDeliverNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_JisProductReceiptNote_Number", + table: "Store_JisProductReceiptNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_JisProductReceiptNoteDetail_MasterID", + table: "Store_JisProductReceiptNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_JisProductReceiptNoteDetail_Number_PackingCode", + table: "Store_JisProductReceiptNoteDetail", + columns: new[] { "Number", "PackingCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_MaterialRequest_Number", + table: "Store_MaterialRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_MaterialRequestDetail_ItemCode", + table: "Store_MaterialRequestDetail", + column: "ItemCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_MaterialRequestDetail_MasterID", + table: "Store_MaterialRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_MaterialRequestDetail_Number_ItemCode_ToLocationCode", + table: "Store_MaterialRequestDetail", + columns: new[] { "Number", "ItemCode", "ToLocationCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_NoOkConvertOkNote_Number", + table: "Store_NoOkConvertOkNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_NoOkConvertOkNoteDetail_MasterID", + table: "Store_NoOkConvertOkNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_NoOkConvertOkNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", + table: "Store_NoOkConvertOkNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_OfflineSettlementNote_Number", + table: "Store_OfflineSettlementNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_OfflineSettlementNoteDetail_MasterID", + table: "Store_OfflineSettlementNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_OfflineSettlementNoteDetail_Number", + table: "Store_OfflineSettlementNoteDetail", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PreparationPlan_Number", + table: "Store_PreparationPlan", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PreparationPlanDetail_MasterID", + table: "Store_PreparationPlanDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PreparationPlanDetail_Number_ItemCode", + table: "Store_PreparationPlanDetail", + columns: new[] { "Number", "ItemCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductionPlan_Number", + table: "Store_ProductionPlan", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductionPlanDetail_MasterID", + table: "Store_ProductionPlanDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductionPlanDetail_Number_ItemCode", + table: "Store_ProductionPlanDetail", + columns: new[] { "Number", "ItemCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductionReturnNote_Number", + table: "Store_ProductionReturnNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductionReturnNoteDetail_MasterID", + table: "Store_ProductionReturnNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductionReturnNoteDetail_Number_ItemCode_FromPackingCode_ToPackingCode_FromLocationCode_ToLocationCode", + table: "Store_ProductionReturnNoteDetail", + columns: new[] { "Number", "ItemCode", "FromPackingCode", "ToPackingCode", "FromLocationCode", "ToLocationCode" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductionReturnRequest_Number", + table: "Store_ProductionReturnRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductionReturnRequestDetail_ItemCode", + table: "Store_ProductionReturnRequestDetail", + column: "ItemCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductionReturnRequestDetail_MasterID", + table: "Store_ProductionReturnRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductionReturnRequestDetail_Number_ItemCode_FromLocationCode", + table: "Store_ProductionReturnRequestDetail", + columns: new[] { "Number", "ItemCode", "FromLocationCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductL7PartsNote_Number", + table: "Store_ProductL7PartsNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductL7PartsNoteDetail_MasterID", + table: "Store_ProductL7PartsNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductL7PartsNoteDetail_Number_ProductNo_Position_Configuration_L7Part", + table: "Store_ProductL7PartsNoteDetail", + columns: new[] { "Number", "ProductNo", "Position", "Configuration", "L7Part" }, + unique: true, + filter: "[ProductNo] IS NOT NULL AND [Position] IS NOT NULL AND [Configuration] IS NOT NULL AND [L7Part] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductReceiptNote_Number", + table: "Store_ProductReceiptNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductReceiptNoteDetail_MasterID", + table: "Store_ProductReceiptNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductReceiptNoteDetail_Number_ItemCode_PackingCode_Lot_Status", + table: "Store_ProductReceiptNoteDetail", + columns: new[] { "Number", "ItemCode", "PackingCode", "Lot", "Status" }, + unique: true, + filter: "[Lot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductReceiptRequest_Number", + table: "Store_ProductReceiptRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductReceiptRequestDetail_MasterID", + table: "Store_ProductReceiptRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductReceiptRequestDetail_Number_ItemCode_LocationCode", + table: "Store_ProductReceiptRequestDetail", + columns: new[] { "Number", "ItemCode", "LocationCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductRecycleMaterialDetail_MasterID", + table: "Store_ProductRecycleMaterialDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductRecycleMaterialDetail_Number_ProductItemCode_ItemCode", + table: "Store_ProductRecycleMaterialDetail", + columns: new[] { "Number", "ProductItemCode", "ItemCode" }); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductRecycleNote_Number", + table: "Store_ProductRecycleNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductRecycleNoteDetail_MasterID", + table: "Store_ProductRecycleNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductRecycleNoteDetail_Number_ItemCode", + table: "Store_ProductRecycleNoteDetail", + columns: new[] { "Number", "ItemCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductRecycleRequest_Number", + table: "Store_ProductRecycleRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductRecycleRequestDetail_MasterID", + table: "Store_ProductRecycleRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ProductRecycleRequestDetail_Number_ItemCode", + table: "Store_ProductRecycleRequestDetail", + columns: new[] { "Number", "ItemCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseOrder_Number", + table: "Store_PurchaseOrder", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseOrderDetail_ItemCode_Number_PoLine", + table: "Store_PurchaseOrderDetail", + columns: new[] { "ItemCode", "Number", "PoLine" }, + unique: true, + filter: "[PoLine] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseOrderDetail_MasterID", + table: "Store_PurchaseOrderDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReceiptNote_Number", + table: "Store_PurchaseReceiptNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReceiptNote_SupplierCode", + table: "Store_PurchaseReceiptNote", + column: "SupplierCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReceiptNoteDetail_MasterID", + table: "Store_PurchaseReceiptNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReceiptRequest_Number", + table: "Store_PurchaseReceiptRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReceiptRequest_SupplierCode", + table: "Store_PurchaseReceiptRequest", + column: "SupplierCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReceiptRequestDetail_MasterID", + table: "Store_PurchaseReceiptRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReceiptRequestDetail_Number_PackingCode", + table: "Store_PurchaseReceiptRequestDetail", + columns: new[] { "Number", "PackingCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReturnNote_Number", + table: "Store_PurchaseReturnNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReturnNoteDetail_MasterID", + table: "Store_PurchaseReturnNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReturnNoteDetail_Number_PackingCode", + table: "Store_PurchaseReturnNoteDetail", + columns: new[] { "Number", "PackingCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReturnRequest_Number", + table: "Store_PurchaseReturnRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReturnRequestDetail_MasterID", + table: "Store_PurchaseReturnRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PurchaseReturnRequestDetail_Number_PackingCode", + table: "Store_PurchaseReturnRequestDetail", + columns: new[] { "Number", "PackingCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PutawayNote_Number", + table: "Store_PutawayNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PutawayNoteDetail_MasterID", + table: "Store_PutawayNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PutawayNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode_ToPackingCode", + table: "Store_PutawayNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "ToPackingCode" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL AND [ToPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_PutawayRequest_Number", + table: "Store_PutawayRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_PutawayRequestDetail_MasterID", + table: "Store_PutawayRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ReceiptAbnormalNote_AsnNumber_Number_SupplierCode_ReceiptNumber", + table: "Store_ReceiptAbnormalNote", + columns: new[] { "AsnNumber", "Number", "SupplierCode", "ReceiptNumber" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ReceiptAbnormalNote_SupplierCode", + table: "Store_ReceiptAbnormalNote", + column: "SupplierCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ReceiptAbnormalNoteDetail_MasterID", + table: "Store_ReceiptAbnormalNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ReceiptAbnormalNoteDetail_Number_PackingCode_ReceiptNumber", + table: "Store_ReceiptAbnormalNoteDetail", + columns: new[] { "Number", "PackingCode", "ReceiptNumber" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_RecycledMaterialReceiptNote_Number", + table: "Store_RecycledMaterialReceiptNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_RecycledMaterialReceiptNoteDetail_MasterID", + table: "Store_RecycledMaterialReceiptNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_RecycledMaterialReceiptNoteDetail_Number_PackingCode", + table: "Store_RecycledMaterialReceiptNoteDetail", + columns: new[] { "Number", "PackingCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_SaleOrder_CustomerCode", + table: "Store_SaleOrder", + column: "CustomerCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_SaleOrder_Number", + table: "Store_SaleOrder", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_SaleOrderDetail_MasterID", + table: "Store_SaleOrderDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_SaleOrderDetail_Number_SoLine_ItemCode", + table: "Store_SaleOrderDetail", + columns: new[] { "Number", "SoLine", "ItemCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ScrapNote_Number", + table: "Store_ScrapNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ScrapNoteDetail_MasterID", + table: "Store_ScrapNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ScrapNoteDetail_Number_ItemCode_FromPackingCode_FromLocationCode_ToLocationCode_FromLot_FromStatus", + table: "Store_ScrapNoteDetail", + columns: new[] { "Number", "ItemCode", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromLot", "FromStatus" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL AND [FromLot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ScrapRequest_Number", + table: "Store_ScrapRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_ScrapRequestDetail_MasterID", + table: "Store_ScrapRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_ScrapRequestDetail_Number_ItemCode_LocationCode", + table: "Store_ScrapRequestDetail", + columns: new[] { "Number", "ItemCode", "LocationCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_SplitPackingRec_FromPackingCode_ToPackingCode", + table: "Store_SplitPackingRec", + columns: new[] { "FromPackingCode", "ToPackingCode" }); + + migrationBuilder.CreateIndex( + name: "IX_Store_SplitPackingRec_ToPackingCode", + table: "Store_SplitPackingRec", + column: "ToPackingCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_SupplierAsn_Number", + table: "Store_SupplierAsn", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_SupplierAsn_SupplierCode", + table: "Store_SupplierAsn", + column: "SupplierCode"); + + migrationBuilder.CreateIndex( + name: "IX_Store_SupplierAsnDetail_MasterID", + table: "Store_SupplierAsnDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_SupplierAsnDetail_Number_ItemCode_PackingCode", + table: "Store_SupplierAsnDetail", + columns: new[] { "Number", "ItemCode", "PackingCode" }, + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_TransferNote_Number", + table: "Store_TransferNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_TransferNoteDetail_MasterID", + table: "Store_TransferNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_TransferNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode_FromStatus_ToStatus", + table: "Store_TransferNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_TransferRequest_Number", + table: "Store_TransferRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_TransferRequestDetail_MasterID", + table: "Store_TransferRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedIssueNote_Number", + table: "Store_UnplannedIssueNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedIssueNoteDetail_MasterID", + table: "Store_UnplannedIssueNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedIssueNoteDetail_Number_PackingCode_ItemCode_Lot_Status", + table: "Store_UnplannedIssueNoteDetail", + columns: new[] { "Number", "PackingCode", "ItemCode", "Lot", "Status" }, + unique: true, + filter: "[Lot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedIssueRequest_Number", + table: "Store_UnplannedIssueRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedIssueRequestDetail_MasterID", + table: "Store_UnplannedIssueRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedIssueRequestDetail_Number_PackingCode_ItemCode_Lot_Status", + table: "Store_UnplannedIssueRequestDetail", + columns: new[] { "Number", "PackingCode", "ItemCode", "Lot", "Status" }, + unique: true, + filter: "[Lot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedReceiptNote_Number", + table: "Store_UnplannedReceiptNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedReceiptNoteDetail_MasterID", + table: "Store_UnplannedReceiptNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedReceiptNoteDetail_Number_PackingCode_ItemCode_Lot_Status", + table: "Store_UnplannedReceiptNoteDetail", + columns: new[] { "Number", "PackingCode", "ItemCode", "Lot", "Status" }, + unique: true, + filter: "[Lot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedReceiptRequest_Number", + table: "Store_UnplannedReceiptRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedReceiptRequestDetail_MasterID", + table: "Store_UnplannedReceiptRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_UnplannedReceiptRequestDetail_Number_PackingCode_ItemCode_Lot_Status", + table: "Store_UnplannedReceiptRequestDetail", + columns: new[] { "Number", "PackingCode", "ItemCode", "Lot", "Status" }, + unique: true, + filter: "[Lot] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_WarehouseTransferNote_Number", + table: "Store_WarehouseTransferNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_WarehouseTransferNoteDetail_MasterID", + table: "Store_WarehouseTransferNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_WarehouseTransferNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode", + table: "Store_WarehouseTransferNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_WipWarehouseAdjustNote_Number", + table: "Store_WipWarehouseAdjustNote", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_WipWarehouseAdjustNoteDetail_MasterID", + table: "Store_WipWarehouseAdjustNoteDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_WipWarehouseAdjustNoteDetail_Number_FromPackingCode_FromLocationCode_ToLocationCode_FromStatus_ToStatus", + table: "Store_WipWarehouseAdjustNoteDetail", + columns: new[] { "Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus" }, + unique: true, + filter: "[FromPackingCode] IS NOT NULL"); + + migrationBuilder.CreateIndex( + name: "IX_Store_WipWarehouseAdjustRequest_Number", + table: "Store_WipWarehouseAdjustRequest", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_WipWarehouseAdjustRequestDetail_MasterID", + table: "Store_WipWarehouseAdjustRequestDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_WorkOrder_Number", + table: "Store_WorkOrder", + column: "Number", + unique: true); + + migrationBuilder.CreateIndex( + name: "IX_Store_WorkOrderDetail_MasterID", + table: "Store_WorkOrderDetail", + column: "MasterID"); + + migrationBuilder.CreateIndex( + name: "IX_Store_WorkOrderDetail_Number_ItemCode", + table: "Store_WorkOrderDetail", + columns: new[] { "Number", "ItemCode" }, + unique: true); + } + + protected override void Down(MigrationBuilder migrationBuilder) + { + migrationBuilder.DropTable( + name: "Job_CheckJobDetail"); + + migrationBuilder.DropTable( + name: "Job_CountJobDetail"); + + migrationBuilder.DropTable( + name: "Job_DeliverJobDetail"); + + migrationBuilder.DropTable( + name: "Job_InspectJobDetail"); + + migrationBuilder.DropTable( + name: "Job_InspectJobSummaryDetail"); + + migrationBuilder.DropTable( + name: "Job_IssueJobDetail"); + + migrationBuilder.DropTable( + name: "Job_JisDeliverJobDetail"); + + migrationBuilder.DropTable( + name: "Job_ProductionReturnJobDetail"); + + migrationBuilder.DropTable( + name: "Job_ProductReceiveJobDetail"); + + migrationBuilder.DropTable( + name: "Job_PurchaseReceiptJobDetail"); + + migrationBuilder.DropTable( + name: "Job_PurchaseReturnJobDetail"); + + migrationBuilder.DropTable( + name: "Job_PutawayJobDetail"); + + migrationBuilder.DropTable( + name: "Job_UnplannedIssueJobDetail"); + + migrationBuilder.DropTable( + name: "Job_UnplannedReceiptJobDetail"); + + migrationBuilder.DropTable( + name: "Store_BackFlushNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_ContainerBindNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_CountAdjustNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_CountAdjustRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_CountNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_CountPlanDetail"); + + migrationBuilder.DropTable( + name: "Store_CustomerAsnDetail"); + + migrationBuilder.DropTable( + name: "Store_CustomerReturnNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_DeliverNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_DeliverPlanDetail"); + + migrationBuilder.DropTable( + name: "Store_DeliverRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_ExchangeData"); + + migrationBuilder.DropTable( + name: "Store_InspectAbnormalNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_InspectNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_InspectNoteSummaryDetail"); + + migrationBuilder.DropTable( + name: "Store_InspectRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_InspectRequestSummaryDetail"); + + migrationBuilder.DropTable( + name: "Store_InventoryInitialNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_InventoryTransferNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_IsolationNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_IssueNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_ItemTransformNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_ItemTransformRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_JisDeliverNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_JisProductReceiptNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_MaterialRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_NoOkConvertOkNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_OfflineSettlementNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_PreparationPlanDetail"); + + migrationBuilder.DropTable( + name: "Store_ProductionPlanDetail"); + + migrationBuilder.DropTable( + name: "Store_ProductionReturnNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_ProductionReturnRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_ProductL7PartsNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_ProductReceiptNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_ProductReceiptRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_ProductRecycleMaterialDetail"); + + migrationBuilder.DropTable( + name: "Store_ProductRecycleNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_ProductRecycleRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_PurchaseOrderDetail"); + + migrationBuilder.DropTable( + name: "Store_PurchaseReceiptNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_PurchaseReceiptRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_PurchaseReturnNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_PurchaseReturnRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_PutawayNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_PutawayRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_ReceiptAbnormalNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_RecycledMaterialReceiptNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_SaleOrderDetail"); + + migrationBuilder.DropTable( + name: "Store_ScrapNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_ScrapRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_SplitPackingRec"); + + migrationBuilder.DropTable( + name: "Store_SupplierAsnDetail"); + + migrationBuilder.DropTable( + name: "Store_TransferNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_TransferRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_UnplannedIssueNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_UnplannedIssueRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_UnplannedReceiptNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_UnplannedReceiptRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_WarehouseTransferNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_WipWarehouseAdjustNoteDetail"); + + migrationBuilder.DropTable( + name: "Store_WipWarehouseAdjustRequestDetail"); + + migrationBuilder.DropTable( + name: "Store_WorkOrderDetail"); + + migrationBuilder.DropTable( + name: "Job_CheckJob"); + + migrationBuilder.DropTable( + name: "Job_CountJob"); + + migrationBuilder.DropTable( + name: "Job_DeliverJob"); + + migrationBuilder.DropTable( + name: "Job_InspectJob"); + + migrationBuilder.DropTable( + name: "Job_IssueJob"); + + migrationBuilder.DropTable( + name: "Job_JisDeliverJob"); + + migrationBuilder.DropTable( + name: "Job_ProductionReturnJob"); + + migrationBuilder.DropTable( + name: "Job_ProductReceiveJob"); + + migrationBuilder.DropTable( + name: "Job_PurchaseReceiptJob"); + + migrationBuilder.DropTable( + name: "Job_PurchaseReturnJob"); + + migrationBuilder.DropTable( + name: "Job_PutawayJob"); + + migrationBuilder.DropTable( + name: "Job_UnplannedIssueJob"); + + migrationBuilder.DropTable( + name: "Job_UnplannedReceiptJob"); + + migrationBuilder.DropTable( + name: "Store_BackFlushNote"); + + migrationBuilder.DropTable( + name: "Store_ContainerBindNote"); + + migrationBuilder.DropTable( + name: "Store_CountAdjustNote"); + + migrationBuilder.DropTable( + name: "Store_CountAdjustRequest"); + + migrationBuilder.DropTable( + name: "Store_CountNote"); + + migrationBuilder.DropTable( + name: "Store_CountPlan"); + + migrationBuilder.DropTable( + name: "Store_CustomerAsn"); + + migrationBuilder.DropTable( + name: "Store_CustomerReturnNote"); + + migrationBuilder.DropTable( + name: "Store_DeliverNote"); + + migrationBuilder.DropTable( + name: "Store_DeliverPlan"); + + migrationBuilder.DropTable( + name: "Store_DeliverRequest"); + + migrationBuilder.DropTable( + name: "Store_InspectAbnormalNote"); + + migrationBuilder.DropTable( + name: "Store_InspectNote"); + + migrationBuilder.DropTable( + name: "Store_InspectRequest"); + + migrationBuilder.DropTable( + name: "Store_InventoryInitialNote"); + + migrationBuilder.DropTable( + name: "Store_InventoryTransferNote"); + + migrationBuilder.DropTable( + name: "Store_IsolationNote"); + + migrationBuilder.DropTable( + name: "Store_IssueNote"); + + migrationBuilder.DropTable( + name: "Store_ItemTransformNote"); + + migrationBuilder.DropTable( + name: "Store_ItemTransformRequest"); + + migrationBuilder.DropTable( + name: "Store_JisDeliverNote"); + + migrationBuilder.DropTable( + name: "Store_JisProductReceiptNote"); + + migrationBuilder.DropTable( + name: "Store_MaterialRequest"); + + migrationBuilder.DropTable( + name: "Store_NoOkConvertOkNote"); + + migrationBuilder.DropTable( + name: "Store_OfflineSettlementNote"); + + migrationBuilder.DropTable( + name: "Store_PreparationPlan"); + + migrationBuilder.DropTable( + name: "Store_ProductionPlan"); + + migrationBuilder.DropTable( + name: "Store_ProductionReturnNote"); + + migrationBuilder.DropTable( + name: "Store_ProductionReturnRequest"); + + migrationBuilder.DropTable( + name: "Store_ProductL7PartsNote"); + + migrationBuilder.DropTable( + name: "Store_ProductReceiptNote"); + + migrationBuilder.DropTable( + name: "Store_ProductReceiptRequest"); + + migrationBuilder.DropTable( + name: "Store_ProductRecycleNote"); + + migrationBuilder.DropTable( + name: "Store_ProductRecycleRequest"); + + migrationBuilder.DropTable( + name: "Store_PurchaseOrder"); + + migrationBuilder.DropTable( + name: "Store_PurchaseReceiptNote"); + + migrationBuilder.DropTable( + name: "Store_PurchaseReceiptRequest"); + + migrationBuilder.DropTable( + name: "Store_PurchaseReturnNote"); + + migrationBuilder.DropTable( + name: "Store_PurchaseReturnRequest"); + + migrationBuilder.DropTable( + name: "Store_PutawayNote"); + + migrationBuilder.DropTable( + name: "Store_PutawayRequest"); + + migrationBuilder.DropTable( + name: "Store_ReceiptAbnormalNote"); + + migrationBuilder.DropTable( + name: "Store_RecycledMaterialReceiptNote"); + + migrationBuilder.DropTable( + name: "Store_SaleOrder"); + + migrationBuilder.DropTable( + name: "Store_ScrapNote"); + + migrationBuilder.DropTable( + name: "Store_ScrapRequest"); + + migrationBuilder.DropTable( + name: "Store_SupplierAsn"); + + migrationBuilder.DropTable( + name: "Store_TransferNote"); + + migrationBuilder.DropTable( + name: "Store_TransferRequest"); + + migrationBuilder.DropTable( + name: "Store_UnplannedIssueNote"); + + migrationBuilder.DropTable( + name: "Store_UnplannedIssueRequest"); + + migrationBuilder.DropTable( + name: "Store_UnplannedReceiptNote"); + + migrationBuilder.DropTable( + name: "Store_UnplannedReceiptRequest"); + + migrationBuilder.DropTable( + name: "Store_WarehouseTransferNote"); + + migrationBuilder.DropTable( + name: "Store_WipWarehouseAdjustNote"); + + migrationBuilder.DropTable( + name: "Store_WipWarehouseAdjustRequest"); + + migrationBuilder.DropTable( + name: "Store_WorkOrder"); + } + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230404020712_Added_Store_Add_SupplierAdress_SupplierName.Designer.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223065640_base.Designer.cs similarity index 96% rename from be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230404020712_Added_Store_Add_SupplierAdress_SupplierName.Designer.cs rename to be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223065640_base.Designer.cs index 5e1a93dfa..0703708b5 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20230404020712_Added_Store_Add_SupplierAdress_SupplierName.Designer.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223065640_base.Designer.cs @@ -13,8 +13,8 @@ using Win_in.Sfs.Wms.Store.EntityFrameworkCore; namespace Win_in.Sfs.Wms.Store.Migrations { [DbContext(typeof(StoreDbContext))] - [Migration("20230404020712_Added_Store_Add_SupplierAddress_SupplierName")] - partial class Added_Store_Add_SupplierAddress_SupplierName + [Migration("20240223065640_base")] + partial class @base { protected override void BuildTargetModel(ModelBuilder modelBuilder) { @@ -3053,6 +3053,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(40)") .HasColumnName("ConcurrencyStamp"); + b.Property("CountPrint") + .HasColumnType("int"); + b.Property("CreationTime") .HasColumnType("datetime2") .HasColumnName("CreationTime"); @@ -3921,6 +3924,10 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); + b.Property("TyrpNumber") + .IsRequired() + .HasColumnType("nvarchar(max)"); + b.Property("WriteTime") .HasColumnType("datetime2"); @@ -4788,6 +4795,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("decimal(18,6)") .HasDefaultValue(0m); + b.Property("InspectDate") + .HasColumnType("datetime2"); + b.Property("InspectQty") .ValueGeneratedOnAdd() .HasColumnType("decimal(18,6)") @@ -5204,6 +5214,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); + b.Property("WarehouseCode") + .HasColumnType("nvarchar(max)"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -11228,6 +11241,7 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnName("TenantId"); b.Property("Type") + .IsRequired() .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -13085,6 +13099,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("WarehouseCode") + .HasColumnType("nvarchar(max)"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -16850,6 +16867,152 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.ToTable("Store_ScrapRequestDetail", (string)null); }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SplitPackingRec", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ArrivalNoticNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasMaxLength(40) + .HasColumnType("nvarchar(40)") + .HasColumnName("ConcurrencyStamp"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("ExtraProperties") + .HasColumnType("nvarchar(max)") + .HasColumnName("ExtraProperties"); + + b.Property("FromLot") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromQty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)"); + + b.Property("FromStdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("FromTopPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromUom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ItemDesc1") + .HasMaxLength(1024) + .HasColumnType("nvarchar(1024)"); + + b.Property("ItemDesc2") + .HasMaxLength(1024) + .HasColumnType("nvarchar(1024)"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("LabelType") + .HasColumnType("int"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("OprType") + .HasColumnType("int"); + + b.Property("PurchaseInfo_AsnNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("PurchaseInfo_PoNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("PutOnShelfNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ReceiptRecNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Remark") + .HasColumnType("nvarchar(max)"); + + b.Property("TaskOrderNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("ToLot") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToQty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)"); + + b.Property("ToStdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("ToTopPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToUom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.HasKey("Id"); + + b.HasIndex("ToPackingCode"); + + b.HasIndex("FromPackingCode", "ToPackingCode"); + + b.ToTable("Store_SplitPackingRec", (string)null); + }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => { b.Property("Id") @@ -17191,6 +17354,7 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnName("TenantId"); b.Property("Type") + .IsRequired() .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -17753,6 +17917,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Priority") .ValueGeneratedOnAdd() .HasColumnType("int") @@ -17776,6 +17943,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedIssueType") + .HasColumnType("int"); + b.Property("UpStreamJobNumber") .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -17803,6 +17973,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("Id") .HasColumnType("uniqueidentifier"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("CreationTime") .HasColumnType("datetime2") .HasColumnName("CreationTime"); @@ -17811,6 +17984,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("CreatorId"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -17909,6 +18085,12 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("ReasonCode") .HasColumnType("nvarchar(max)"); @@ -18051,6 +18233,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -18064,6 +18249,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedIssueType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -18083,6 +18271,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -18099,6 +18290,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -18225,6 +18419,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -18234,6 +18431,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") @@ -18410,6 +18610,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -18424,6 +18627,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); + b.Property("UnplannedIssueType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -18443,6 +18649,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -18459,6 +18668,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -18528,6 +18740,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -18537,6 +18752,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") @@ -18673,6 +18891,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Priority") .ValueGeneratedOnAdd() .HasColumnType("int") @@ -18696,6 +18917,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedReceiptType") + .HasColumnType("int"); + b.Property("UpStreamJobNumber") .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -18723,6 +18947,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("Id") .HasColumnType("uniqueidentifier"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("CreationTime") .HasColumnType("datetime2") .HasColumnName("CreationTime"); @@ -18731,6 +18958,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("CreatorId"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -18829,6 +19059,12 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("ReasonCode") .HasColumnType("nvarchar(max)"); @@ -18971,6 +19207,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -18984,6 +19223,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedReceiptType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -19003,6 +19245,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -19019,6 +19264,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -19145,6 +19393,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -19154,6 +19405,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") @@ -19330,6 +19584,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -19344,6 +19601,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); + b.Property("UnplannedReceiptType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -19363,6 +19623,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -19379,6 +19642,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -19448,6 +19714,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -19457,11 +19726,17 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") .HasColumnName("Qty"); + b.Property("ReasonCode") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -19763,7 +20038,7 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); }); - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNote", b => { b.Property("Id") .HasColumnType("uniqueidentifier"); @@ -19777,6 +20052,12 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(40)") .HasColumnName("ConcurrencyStamp"); + b.Property("ConfirmTime") + .HasColumnType("datetime2"); + + b.Property("Confirmed") + .HasColumnType("bit"); + b.Property("CreationTime") .HasColumnType("datetime2") .HasColumnName("CreationTime"); @@ -19785,33 +20066,14 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("CreatorId"); - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") + b.Property("JobNumber") .HasMaxLength(64) .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); + .HasColumnName("JobNumber"); b.Property("LastModificationTime") .HasColumnType("datetime2") @@ -19821,20 +20083,573 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("LastModifierId"); - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - b.Property("Number") .IsRequired() .HasMaxLength(64) .HasColumnType("nvarchar(64)") .HasColumnName("Number"); - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("RequestNumber") + .HasColumnType("nvarchar(max)"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("Type") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Worker") + .HasColumnType("nvarchar(max)"); + + b.HasKey("Id"); + + b.HasIndex("Number") + .IsUnique(); + + b.ToTable("Store_WipWarehouseAdjustNote", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNoteDetail", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ArriveDate") + .HasColumnType("datetime2"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("ExpireDate") + .HasColumnType("datetime2"); + + b.Property("FromContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("FromLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationArea"); + + b.Property("FromLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationCode"); + + b.Property("FromLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationErpCode"); + + b.Property("FromLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationGroup"); + + b.Property("FromLot") + .HasColumnType("nvarchar(max)"); + + b.Property("FromPackingCode") + .HasColumnType("nvarchar(450)"); + + b.Property("FromStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromWarehouseCode"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemCode"); + + b.Property("ItemDesc1") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc1"); + + b.Property("ItemDesc2") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc2"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemName"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("MasterID") + .HasColumnType("uniqueidentifier"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("ProduceDate") + .HasColumnType("datetime2"); + + b.Property("Qty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)") + .HasColumnName("Qty"); + + b.Property("Reason") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ReasonCode") + .HasMaxLength(4096) + .HasColumnType("nvarchar(max)"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("StdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("SupplierBatch") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("SupplierBatch"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("ToContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationArea"); + + b.Property("ToLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationCode"); + + b.Property("ToLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationErpCode"); + + b.Property("ToLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationGroup"); + + b.Property("ToLot") + .HasColumnType("nvarchar(max)"); + + b.Property("ToPackingCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToWarehouseCode"); + + b.Property("Uom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Uom"); + + b.HasKey("Id"); + + b.HasIndex("MasterID"); + + b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") + .IsUnique() + .HasFilter("[FromPackingCode] IS NOT NULL"); + + b.ToTable("Store_WipWarehouseAdjustNoteDetail", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequest", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ActiveDate") + .HasColumnType("datetime2"); + + b.Property("AutoAgree") + .HasColumnType("bit"); + + b.Property("AutoCompleteJob") + .HasColumnType("bit"); + + b.Property("AutoHandle") + .HasColumnType("bit"); + + b.Property("AutoSubmit") + .HasColumnType("bit"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasMaxLength(40) + .HasColumnType("nvarchar(40)") + .HasColumnName("ConcurrencyStamp"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("DirectCreateNote") + .HasColumnType("bit"); + + b.Property("ExtraProperties") + .HasColumnType("nvarchar(max)") + .HasColumnName("ExtraProperties"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("RequestStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("Type") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Worker") + .HasColumnType("nvarchar(max)"); + + b.HasKey("Id"); + + b.HasIndex("Number") + .IsUnique(); + + b.ToTable("Store_WipWarehouseAdjustRequest", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequestDetail", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ArriveDate") + .HasColumnType("datetime2"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("ExpireDate") + .HasColumnType("datetime2"); + + b.Property("FromContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("FromLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationArea"); + + b.Property("FromLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationCode"); + + b.Property("FromLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationErpCode"); + + b.Property("FromLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationGroup"); + + b.Property("FromLot") + .HasColumnType("nvarchar(max)"); + + b.Property("FromPackingCode") + .HasColumnType("nvarchar(max)"); + + b.Property("FromStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromWarehouseCode"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemCode"); + + b.Property("ItemDesc1") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc1"); + + b.Property("ItemDesc2") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc2"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemName"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("MasterID") + .HasColumnType("uniqueidentifier"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("ProduceDate") + .HasColumnType("datetime2"); + + b.Property("Qty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)") + .HasColumnName("Qty"); + + b.Property("Reason") + .HasMaxLength(4096) + .HasColumnType("nvarchar(max)"); + + b.Property("ReasonCode") + .HasMaxLength(4096) + .HasColumnType("nvarchar(max)"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("StdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("SupplierBatch") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("SupplierBatch"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("ToContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationArea"); + + b.Property("ToLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationCode"); + + b.Property("ToLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationErpCode"); + + b.Property("ToLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationGroup"); + + b.Property("ToLot") + .HasColumnType("nvarchar(max)"); + + b.Property("ToPackingCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToWarehouseCode"); + + b.Property("Uom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Uom"); + + b.HasKey("Id"); + + b.HasIndex("MasterID"); + + b.ToTable("Store_WipWarehouseAdjustRequestDetail", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ActiveDate") + .HasColumnType("datetime2"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasMaxLength(40) + .HasColumnType("nvarchar(40)") + .HasColumnName("ConcurrencyStamp"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("EffectiveDate") + .HasColumnType("datetime2"); + + b.Property("ExtraProperties") + .HasColumnType("nvarchar(max)") + .HasColumnName("ExtraProperties"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemCode"); + + b.Property("ItemDesc1") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc1"); + + b.Property("ItemDesc2") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc2"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemName"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("LocationCode") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("Op") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") @@ -20611,6 +21426,24 @@ namespace Win_in.Sfs.Wms.Store.Migrations .IsRequired(); }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNoteDetail", b => + { + b.HasOne("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNote", null) + .WithMany("Details") + .HasForeignKey("MasterID") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequestDetail", b => + { + b.HasOne("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequest", null) + .WithMany("Details") + .HasForeignKey("MasterID") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => { b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) @@ -20963,6 +21796,16 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Navigation("Details"); }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNote", b => + { + b.Navigation("Details"); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequest", b => + { + b.Navigation("Details"); + }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => { b.Navigation("Details"); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223065640_base.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223065640_base.cs new file mode 100644 index 000000000..a802febf7 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/20240223065640_base.cs @@ -0,0 +1,19 @@ +using Microsoft.EntityFrameworkCore.Migrations; + +#nullable disable + +namespace Win_in.Sfs.Wms.Store.Migrations +{ + public partial class @base : Migration + { + protected override void Up(MigrationBuilder migrationBuilder) + { + + } + + protected override void Down(MigrationBuilder migrationBuilder) + { + + } + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/StoreDbContextModelSnapshot.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/StoreDbContextModelSnapshot.cs index 6a513c945..4976f8be9 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/StoreDbContextModelSnapshot.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Migrations/StoreDbContextModelSnapshot.cs @@ -3922,6 +3922,10 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); + b.Property("TyrpNumber") + .IsRequired() + .HasColumnType("nvarchar(max)"); + b.Property("WriteTime") .HasColumnType("datetime2"); @@ -4789,6 +4793,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("decimal(18,6)") .HasDefaultValue(0m); + b.Property("InspectDate") + .HasColumnType("datetime2"); + b.Property("InspectQty") .ValueGeneratedOnAdd() .HasColumnType("decimal(18,6)") @@ -11232,6 +11239,7 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnName("TenantId"); b.Property("Type") + .IsRequired() .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -16857,6 +16865,152 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.ToTable("Store_ScrapRequestDetail", (string)null); }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SplitPackingRec", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ArrivalNoticNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasMaxLength(40) + .HasColumnType("nvarchar(40)") + .HasColumnName("ConcurrencyStamp"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("ExtraProperties") + .HasColumnType("nvarchar(max)") + .HasColumnName("ExtraProperties"); + + b.Property("FromLot") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromQty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)"); + + b.Property("FromStdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("FromTopPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromUom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ItemDesc1") + .HasMaxLength(1024) + .HasColumnType("nvarchar(1024)"); + + b.Property("ItemDesc2") + .HasMaxLength(1024) + .HasColumnType("nvarchar(1024)"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("LabelType") + .HasColumnType("int"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("OprType") + .HasColumnType("int"); + + b.Property("PurchaseInfo_AsnNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("PurchaseInfo_PoNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("PutOnShelfNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ReceiptRecNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Remark") + .HasColumnType("nvarchar(max)"); + + b.Property("TaskOrderNumber") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("ToLot") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToQty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)"); + + b.Property("ToStdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("ToTopPackingCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToUom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.HasKey("Id"); + + b.HasIndex("ToPackingCode"); + + b.HasIndex("FromPackingCode", "ToPackingCode"); + + b.ToTable("Store_SplitPackingRec", (string)null); + }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.SupplierAsn", b => { b.Property("Id") @@ -17761,6 +17915,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Priority") .ValueGeneratedOnAdd() .HasColumnType("int") @@ -17784,6 +17941,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedIssueType") + .HasColumnType("int"); + b.Property("UpStreamJobNumber") .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -17811,6 +17971,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("Id") .HasColumnType("uniqueidentifier"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("CreationTime") .HasColumnType("datetime2") .HasColumnName("CreationTime"); @@ -17819,6 +17982,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("CreatorId"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -17917,6 +18083,12 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("ReasonCode") .HasColumnType("nvarchar(max)"); @@ -18059,6 +18231,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -18072,6 +18247,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedIssueType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -18091,6 +18269,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -18107,6 +18288,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -18233,6 +18417,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -18242,6 +18429,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") @@ -18418,6 +18608,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -18432,6 +18625,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); + b.Property("UnplannedIssueType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -18451,6 +18647,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -18467,6 +18666,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -18536,6 +18738,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -18545,6 +18750,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") @@ -18681,6 +18889,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Priority") .ValueGeneratedOnAdd() .HasColumnType("int") @@ -18704,6 +18915,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedReceiptType") + .HasColumnType("int"); + b.Property("UpStreamJobNumber") .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -18731,6 +18945,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("Id") .HasColumnType("uniqueidentifier"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("CreationTime") .HasColumnType("datetime2") .HasColumnName("CreationTime"); @@ -18739,6 +18956,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("CreatorId"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -18837,6 +19057,12 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("ReasonCode") .HasColumnType("nvarchar(max)"); @@ -18979,6 +19205,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -18992,6 +19221,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasMaxLength(64) .HasColumnType("nvarchar(64)"); + b.Property("UnplannedReceiptType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -19011,6 +19243,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -19027,6 +19262,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -19153,6 +19391,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -19162,6 +19403,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") @@ -19338,6 +19582,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OANumber") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -19352,6 +19599,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); + b.Property("UnplannedReceiptType") + .HasColumnType("int"); + b.Property("Worker") .HasColumnType("nvarchar(max)"); @@ -19371,6 +19621,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ArriveDate") .HasColumnType("datetime2"); + b.Property("CaseCode") + .HasColumnType("nvarchar(max)"); + b.Property("ContainerCode") .HasMaxLength(64) .HasColumnType("nvarchar(64)") @@ -19387,6 +19640,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ExpireDate") .HasColumnType("datetime2"); + b.Property("Explain") + .HasColumnType("nvarchar(max)"); + b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); @@ -19456,6 +19712,9 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(64)") .HasColumnName("Number"); + b.Property("OnceBusiCode") + .HasColumnType("nvarchar(max)"); + b.Property("PackingCode") .IsRequired() .HasMaxLength(64) @@ -19465,11 +19724,17 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Property("ProduceDate") .HasColumnType("datetime2"); + b.Property("ProjCapacityCode") + .HasColumnType("nvarchar(max)"); + b.Property("Qty") .HasPrecision(18, 6) .HasColumnType("decimal(18,6)") .HasColumnName("Qty"); + b.Property("ReasonCode") + .HasColumnType("nvarchar(max)"); + b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") @@ -19771,7 +20036,7 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.ToTable("Store_WarehouseTransferNoteDetail", (string)null); }); - modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNote", b => { b.Property("Id") .HasColumnType("uniqueidentifier"); @@ -19785,6 +20050,12 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("nvarchar(40)") .HasColumnName("ConcurrencyStamp"); + b.Property("ConfirmTime") + .HasColumnType("datetime2"); + + b.Property("Confirmed") + .HasColumnType("bit"); + b.Property("CreationTime") .HasColumnType("datetime2") .HasColumnName("CreationTime"); @@ -19793,33 +20064,14 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("CreatorId"); - b.Property("EffectiveDate") - .HasColumnType("datetime2"); - b.Property("ExtraProperties") .HasColumnType("nvarchar(max)") .HasColumnName("ExtraProperties"); - b.Property("ItemCode") - .IsRequired() - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemCode"); - - b.Property("ItemDesc1") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc1"); - - b.Property("ItemDesc2") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)") - .HasColumnName("ItemDesc2"); - - b.Property("ItemName") + b.Property("JobNumber") .HasMaxLength(64) .HasColumnType("nvarchar(64)") - .HasColumnName("ItemName"); + .HasColumnName("JobNumber"); b.Property("LastModificationTime") .HasColumnType("datetime2") @@ -19829,36 +20081,589 @@ namespace Win_in.Sfs.Wms.Store.Migrations .HasColumnType("uniqueidentifier") .HasColumnName("LastModifierId"); - b.Property("LocationCode") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - b.Property("Number") .IsRequired() .HasMaxLength(64) .HasColumnType("nvarchar(64)") .HasColumnName("Number"); - b.Property("Op") - .HasMaxLength(64) - .HasColumnType("nvarchar(64)"); - - b.Property("Qty") - .HasPrecision(18, 6) - .HasColumnType("decimal(18,6)") - .HasColumnName("Qty"); - b.Property("Remark") .HasMaxLength(3072) .HasColumnType("nvarchar(3072)") .HasColumnName("Remark"); + b.Property("RequestNumber") + .HasColumnType("nvarchar(max)"); + b.Property("TenantId") .HasColumnType("uniqueidentifier") .HasColumnName("TenantId"); b.Property("Type") - .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Worker") + .HasColumnType("nvarchar(max)"); + + b.HasKey("Id"); + + b.HasIndex("Number") + .IsUnique(); + + b.ToTable("Store_WipWarehouseAdjustNote", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNoteDetail", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ArriveDate") + .HasColumnType("datetime2"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("ExpireDate") + .HasColumnType("datetime2"); + + b.Property("FromContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("FromLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationArea"); + + b.Property("FromLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationCode"); + + b.Property("FromLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationErpCode"); + + b.Property("FromLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationGroup"); + + b.Property("FromLot") + .HasColumnType("nvarchar(max)"); + + b.Property("FromPackingCode") + .HasColumnType("nvarchar(450)"); + + b.Property("FromStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromWarehouseCode"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemCode"); + + b.Property("ItemDesc1") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc1"); + + b.Property("ItemDesc2") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc2"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemName"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("MasterID") + .HasColumnType("uniqueidentifier"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("ProduceDate") + .HasColumnType("datetime2"); + + b.Property("Qty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)") + .HasColumnName("Qty"); + + b.Property("Reason") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ReasonCode") + .HasMaxLength(4096) + .HasColumnType("nvarchar(max)"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("StdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("SupplierBatch") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("SupplierBatch"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("ToContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationArea"); + + b.Property("ToLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationCode"); + + b.Property("ToLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationErpCode"); + + b.Property("ToLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationGroup"); + + b.Property("ToLot") + .HasColumnType("nvarchar(max)"); + + b.Property("ToPackingCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToWarehouseCode"); + + b.Property("Uom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Uom"); + + b.HasKey("Id"); + + b.HasIndex("MasterID"); + + b.HasIndex("Number", "FromPackingCode", "FromLocationCode", "ToLocationCode", "FromStatus", "ToStatus") + .IsUnique() + .HasFilter("[FromPackingCode] IS NOT NULL"); + + b.ToTable("Store_WipWarehouseAdjustNoteDetail", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequest", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ActiveDate") + .HasColumnType("datetime2"); + + b.Property("AutoAgree") + .HasColumnType("bit"); + + b.Property("AutoCompleteJob") + .HasColumnType("bit"); + + b.Property("AutoHandle") + .HasColumnType("bit"); + + b.Property("AutoSubmit") + .HasColumnType("bit"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasMaxLength(40) + .HasColumnType("nvarchar(40)") + .HasColumnName("ConcurrencyStamp"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("DirectCreateNote") + .HasColumnType("bit"); + + b.Property("ExtraProperties") + .HasColumnType("nvarchar(max)") + .HasColumnName("ExtraProperties"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("RequestStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("Type") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Worker") + .HasColumnType("nvarchar(max)"); + + b.HasKey("Id"); + + b.HasIndex("Number") + .IsUnique(); + + b.ToTable("Store_WipWarehouseAdjustRequest", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequestDetail", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ArriveDate") + .HasColumnType("datetime2"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("ExpireDate") + .HasColumnType("datetime2"); + + b.Property("FromContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("FromLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationArea"); + + b.Property("FromLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationCode"); + + b.Property("FromLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationErpCode"); + + b.Property("FromLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromLocationGroup"); + + b.Property("FromLot") + .HasColumnType("nvarchar(max)"); + + b.Property("FromPackingCode") + .HasColumnType("nvarchar(max)"); + + b.Property("FromStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("FromWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("FromWarehouseCode"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemCode"); + + b.Property("ItemDesc1") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc1"); + + b.Property("ItemDesc2") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc2"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemName"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("MasterID") + .HasColumnType("uniqueidentifier"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("ProduceDate") + .HasColumnType("datetime2"); + + b.Property("Qty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)") + .HasColumnName("Qty"); + + b.Property("Reason") + .HasMaxLength(4096) + .HasColumnType("nvarchar(max)"); + + b.Property("ReasonCode") + .HasMaxLength(4096) + .HasColumnType("nvarchar(max)"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("StdPackQty") + .HasColumnType("decimal(18,6)"); + + b.Property("SupplierBatch") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("SupplierBatch"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("ToContainerCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToLocationArea") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationArea"); + + b.Property("ToLocationCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationCode"); + + b.Property("ToLocationErpCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationErpCode"); + + b.Property("ToLocationGroup") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToLocationGroup"); + + b.Property("ToLot") + .HasColumnType("nvarchar(max)"); + + b.Property("ToPackingCode") + .HasColumnType("nvarchar(max)"); + + b.Property("ToStatus") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("ToWarehouseCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ToWarehouseCode"); + + b.Property("Uom") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Uom"); + + b.HasKey("Id"); + + b.HasIndex("MasterID"); + + b.ToTable("Store_WipWarehouseAdjustRequestDetail", (string)null); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => + { + b.Property("Id") + .HasColumnType("uniqueidentifier"); + + b.Property("ActiveDate") + .HasColumnType("datetime2"); + + b.Property("ConcurrencyStamp") + .IsConcurrencyToken() + .HasMaxLength(40) + .HasColumnType("nvarchar(40)") + .HasColumnName("ConcurrencyStamp"); + + b.Property("CreationTime") + .HasColumnType("datetime2") + .HasColumnName("CreationTime"); + + b.Property("CreatorId") + .HasColumnType("uniqueidentifier") + .HasColumnName("CreatorId"); + + b.Property("EffectiveDate") + .HasColumnType("datetime2"); + + b.Property("ExtraProperties") + .HasColumnType("nvarchar(max)") + .HasColumnName("ExtraProperties"); + + b.Property("ItemCode") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemCode"); + + b.Property("ItemDesc1") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc1"); + + b.Property("ItemDesc2") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemDesc2"); + + b.Property("ItemName") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("ItemName"); + + b.Property("LastModificationTime") + .HasColumnType("datetime2") + .HasColumnName("LastModificationTime"); + + b.Property("LastModifierId") + .HasColumnType("uniqueidentifier") + .HasColumnName("LastModifierId"); + + b.Property("LocationCode") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Number") + .IsRequired() + .HasMaxLength(64) + .HasColumnType("nvarchar(64)") + .HasColumnName("Number"); + + b.Property("Op") + .HasMaxLength(64) + .HasColumnType("nvarchar(64)"); + + b.Property("Qty") + .HasPrecision(18, 6) + .HasColumnType("decimal(18,6)") + .HasColumnName("Qty"); + + b.Property("Remark") + .HasMaxLength(3072) + .HasColumnType("nvarchar(3072)") + .HasColumnName("Remark"); + + b.Property("TenantId") + .HasColumnType("uniqueidentifier") + .HasColumnName("TenantId"); + + b.Property("Type") + .IsRequired() .HasMaxLength(64) .HasColumnType("nvarchar(64)"); @@ -20619,6 +21424,24 @@ namespace Win_in.Sfs.Wms.Store.Migrations .IsRequired(); }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNoteDetail", b => + { + b.HasOne("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNote", null) + .WithMany("Details") + .HasForeignKey("MasterID") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequestDetail", b => + { + b.HasOne("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequest", null) + .WithMany("Details") + .HasForeignKey("MasterID") + .OnDelete(DeleteBehavior.Cascade) + .IsRequired(); + }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrderDetail", b => { b.HasOne("Win_in.Sfs.Wms.Store.Domain.WorkOrder", null) @@ -20971,6 +21794,16 @@ namespace Win_in.Sfs.Wms.Store.Migrations b.Navigation("Details"); }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustNote", b => + { + b.Navigation("Details"); + }); + + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WipWarehouseAdjustRequest", b => + { + b.Navigation("Details"); + }); + modelBuilder.Entity("Win_in.Sfs.Wms.Store.Domain.WorkOrder", b => { b.Navigation("Details"); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/ContainerNotes/ContainerNoteDbContextModelCreatingExtensions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/ContainerNotes/ContainerNoteDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..7b7120af4 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/ContainerNotes/ContainerNoteDbContextModelCreatingExtensions.cs @@ -0,0 +1,56 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; + +public static class ContainerNoteDbContextModelCreatingExtensions +{ + public static void ConfigureContainerNote(this ModelBuilder builder, StoreModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(ContainerNote), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsStoreBase(); + + //Properties + b.Property(q => q.JobNumber).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ContainerType).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.RequestLocationCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.SpecificationsType).HasMaxLength(SfsPropertyConst.CodeLength); + + //Relations + b.HasMany(q => q.Details).WithOne().HasForeignKey(d => d.MasterID).IsRequired(); + + //Indexes + b.HasIndex(q => new { q.Number }).IsUnique(); + }); + + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(ContainerNoteDetail), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsStoreBase(); + //Configure Sfs store detail properties + b.ConfigureSfsStoreDetailBase(); + + //Properties + b.Property(q => q.ToLocationCode).HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.FromLocationCode).HasMaxLength(SfsPropertyConst.CodeLength); + + //Relations + + //Indexes + b.HasIndex(q => new { q.Number }).IsUnique(); + + }); + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/ContainerNotes/ContainerNoteEfCoreRepository.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/ContainerNotes/ContainerNoteEfCoreRepository.cs new file mode 100644 index 000000000..247fcffec --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/ContainerNotes/ContainerNoteEfCoreRepository.cs @@ -0,0 +1,11 @@ +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; + +public class ContainerNoteEfCoreRepository : SfsStoreEfCoreRepositoryBase, IContainerNoteRepository +{ + public ContainerNoteEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/IssueNotes/IssueNoteDbContextModelCreatingExtensions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/IssueNotes/IssueNoteDbContextModelCreatingExtensions.cs index a29f693e5..3cbe63637 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/IssueNotes/IssueNoteDbContextModelCreatingExtensions.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Notes/IssueNotes/IssueNoteDbContextModelCreatingExtensions.cs @@ -50,6 +50,7 @@ public static class IssueNoteDbContextModelCreatingExtensions b.Property(q => q.OnTheWayLocationCode).HasMaxLength(SfsPropertyConst.CodeLength); b.Property(q => q.FromStatus).HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); b.Property(q => q.ToStatus).HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); + b.Property(q => q.RecommendType).HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); //Relations diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Requests/ContainerRequests/ContainerRequestDbContextModelCreatingExtensions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Requests/ContainerRequests/ContainerRequestDbContextModelCreatingExtensions.cs new file mode 100644 index 000000000..1146c9219 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Requests/ContainerRequests/ContainerRequestDbContextModelCreatingExtensions.cs @@ -0,0 +1,53 @@ +using Microsoft.EntityFrameworkCore; +using Volo.Abp.EntityFrameworkCore.Modeling; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; + +public static class ContainerRequestDbContextModelCreatingExtensions +{ + public static void ConfigureContainerRequest(this ModelBuilder builder, StoreModelBuilderConfigurationOptions options) + { + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(ContainerRequest), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsStoreBase(); + + //Properties + b.Property(q => q.RequestLocationCode).IsRequired().HasMaxLength(SfsPropertyConst.CodeLength); + b.Property(q => q.ContainerType).HasMaxLength(SfsPropertyConst.NameLength); + b.Property(q => q.SpecificationsType).HasMaxLength(SfsPropertyConst.NameLength); + b.Property(q => q.RequestStatus).IsRequired().HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); + + //Relations + b.HasMany(q => q.Details).WithOne().HasForeignKey(d => d.MasterID).IsRequired(); + + //Indexes + b.HasIndex(q => new { q.Number }).IsUnique(); + }); + + builder.Entity(b => + { + //Configure table & schema name + b.ToTable(options.TablePrefix + nameof(ContainerRequestDetail), options.Schema); + //Configure ABP properties + b.ConfigureByConvention(); + //Configure Sfs base properties + b.ConfigureSfsStoreBase(); + //Configure Sfs store detail properties + b.ConfigureSfsStoreDetailBase(); + + //Properties + + //Relations + + //Indexes + b.HasIndex(q => new { q.Number }).IsUnique(); + }); + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Requests/ContainerRequests/ContainerRequestEfCoreRepository.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Requests/ContainerRequests/ContainerRequestEfCoreRepository.cs new file mode 100644 index 000000000..07917c6f5 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Requests/ContainerRequests/ContainerRequestEfCoreRepository.cs @@ -0,0 +1,11 @@ +using Volo.Abp.EntityFrameworkCore; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; + +public class ContainerRequestEfCoreRepository : SfsStoreEfCoreRepositoryBase, IContainerRequestRepository +{ + public ContainerRequestEfCoreRepository(IDbContextProvider dbContextProvider) : base(dbContextProvider) + { + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Requests/MaterialRequests/MaterialRequestDbContextModelCreatingExtensions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Requests/MaterialRequests/MaterialRequestDbContextModelCreatingExtensions.cs index 27f04bab8..cdfbf4737 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Requests/MaterialRequests/MaterialRequestDbContextModelCreatingExtensions.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Requests/MaterialRequests/MaterialRequestDbContextModelCreatingExtensions.cs @@ -54,6 +54,7 @@ public static class MaterialRequestDbContextModelCreatingExtensions b.Property(q => q.IssuedQty).HasPrecision(18, 6); b.Property(q => q.ReceivedQty).HasPrecision(18, 6); b.Property(q => q.Status).HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); + b.Property(q => q.RecommendType).HasMaxLength(SfsPropertyConst.NameLength).HasConversion(); //Relations diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreDbContext.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreDbContext.cs index 9a5dbfa35..d33e47fe6 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreDbContext.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreDbContext.cs @@ -2,6 +2,7 @@ using Microsoft.EntityFrameworkCore; using Volo.Abp.Data; using Volo.Abp.EntityFrameworkCore; using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Equipments; namespace Win_in.Sfs.Wms.Store.EntityFrameworkCore; @@ -17,6 +18,7 @@ public class StoreDbContext : AbpDbContext, IStoreDbContext public DbSet TransferRequests { get; set; } public DbSet ProductReceiptRequests { get; set; } public DbSet MaterialRequests { get; set; } + public DbSet ContainerRequests { get; set; } public DbSet DeliverRequests { get; set; } public DbSet InspectRequests { get; set; } public DbSet PutawayRequest { get; set; } @@ -67,6 +69,7 @@ public class StoreDbContext : AbpDbContext, IStoreDbContext public DbSet InventoryTransferNotes { get; set; } public DbSet WarehouseTransferNotes { get; set; } public DbSet IssueNotes { get; set; } + public DbSet ContainerNotes { get; set; } public DbSet UnplannedReceiptNotes { get; set; } public DbSet UnplannedIssueNotes { get; set; } public DbSet IsolationNotes { get; set; } @@ -91,10 +94,12 @@ public class StoreDbContext : AbpDbContext, IStoreDbContext public DbSet InspectJobs { get; set; } public DbSet PutawayJobs { get; set; } public DbSet IssueJobs { get; set; } + public DbSet ContainerJobs { get; set; } public DbSet DeliverJobs { get; set; } public DbSet JisDeliverJobs { get; set; } public DbSet PurchaseReturnJobs { get; set; } public DbSet ProductReceiveJobs { get; set; } + public DbSet ProductRecycleJobs { get; set; } public DbSet CheckJobs { get; set; } public DbSet CountJobs { get; set; } public DbSet UnplannedIssueJobs { get; set; } @@ -104,6 +109,7 @@ public class StoreDbContext : AbpDbContext, IStoreDbContext #endregion public DbSet ExchangeDatas { get; set; } + public DbSet EquipmentRecords { get; set; } public StoreDbContext(DbContextOptions options) : base(options) diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreDbContextModelCreatingExtensions.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreDbContextModelCreatingExtensions.cs index 38813f279..a325299a5 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreDbContextModelCreatingExtensions.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreDbContextModelCreatingExtensions.cs @@ -29,6 +29,11 @@ public static class StoreDbContextModelCreatingExtensions builder.ConfigureSaleOrder(options); builder.ConfigureWorkOrder(options); + builder.ConfigureEquipmentRecord(options); + //builder.ConfigureEquipmentLocCap(options); + + + #endregion #region Plans @@ -50,6 +55,7 @@ public static class StoreDbContextModelCreatingExtensions builder.ConfigurePurchaseReceiptRequest(options); builder.ConfigureMaterialRequest(options); builder.ConfigureDeliverRequest(options); + builder.ConfigureContainerRequest(options); builder.ConfigureInspectRequest(options); builder.ConfigureUnplannedIssueRequest(options); builder.ConfigureUnplannedReceiptRequest(options); @@ -81,6 +87,7 @@ public static class StoreDbContextModelCreatingExtensions builder.ConfigureInventoryTransferNote(options); builder.ConfigureWarehouseTransferNote(options); builder.ConfigureIssueNote(options); + builder.ConfigureContainerNote(options); builder.ConfigureUnplannedReceiptNote(options); builder.ConfigureUnplannedIssueNote(options); builder.ConfigureIsolationNote(options); @@ -106,10 +113,12 @@ public static class StoreDbContextModelCreatingExtensions builder.ConfigureInspectJob(options); builder.ConfigurePutawayJob(options); builder.ConfigureIssueJob(options); + builder.ConfigureContainerJob(options); builder.ConfigureDeliverJob(options); builder.ConfigureJisDeliverJob(options); builder.ConfigurePurchaseReturnJob(options); builder.ConfigureProductReceiveJob(options); + builder.ConfigureProductRecycleJob(options); builder.ConfigureCheckJob(options); builder.ConfigureCountJob(options); builder.ConfigureUnplannedIssueJob(options); @@ -122,7 +131,6 @@ public static class StoreDbContextModelCreatingExtensions //设置decimal的默认小数位数 builder.ConfigurePrecisionOfDecimal(); - } } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreEntityFrameworkCoreModule.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreEntityFrameworkCoreModule.cs index d51a8a347..24dc4c2c4 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreEntityFrameworkCoreModule.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/StoreEntityFrameworkCoreModule.cs @@ -32,6 +32,7 @@ public class StoreEntityFrameworkCoreModule : AbpModule context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); + context.Services.AddTransient(); #endregion @@ -53,7 +54,8 @@ public class StoreEntityFrameworkCoreModule : AbpModule context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); - context.Services.AddTransient(); + context.Services.AddTransient(); + context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); @@ -86,6 +88,7 @@ public class StoreEntityFrameworkCoreModule : AbpModule context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); + context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); @@ -111,10 +114,12 @@ public class StoreEntityFrameworkCoreModule : AbpModule context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); + context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); + context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); context.Services.AddTransient(); @@ -124,6 +129,7 @@ public class StoreEntityFrameworkCoreModule : AbpModule #endregion context.Services.AddTransient(); + } private void ConfigureEntity() @@ -168,6 +174,8 @@ public class StoreEntityFrameworkCoreModule : AbpModule orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); + options.Entity(orderOptions => + orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => @@ -214,6 +222,8 @@ public class StoreEntityFrameworkCoreModule : AbpModule orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); + options.Entity(orderOptions => + orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => @@ -277,10 +287,14 @@ public class StoreEntityFrameworkCoreModule : AbpModule orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); + options.Entity(orderOptions => + orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); + options.Entity(orderOptions => + orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => orderOptions.DefaultWithDetailsFunc = query => query.Include(o => o.Details)); options.Entity(orderOptions => diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Win_in.Sfs.Wms.Store.EntityFrameworkCore.csproj b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Win_in.Sfs.Wms.Store.EntityFrameworkCore.csproj index ad144b5fb..b0aebac8d 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Win_in.Sfs.Wms.Store.EntityFrameworkCore.csproj +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.EntityFrameworkCore/Win_in.Sfs.Wms.Store.EntityFrameworkCore.csproj @@ -38,10 +38,9 @@ - + - diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Jobs/ContainerJobAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Jobs/ContainerJobAutoMapperProfile.cs new file mode 100644 index 000000000..26d48ee90 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Jobs/ContainerJobAutoMapperProfile.cs @@ -0,0 +1,21 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Event; + +public partial class StoreEventAutoMapperProfile : Profile +{ + + private void ContainerJobAutoMapperProfile() + { + CreateMap() + .ForMember(x => x.JobNumber, y => y.MapFrom(d => d.Number)) + .Ignore(x => x.Confirmed) + .Ignore(x => x.ActiveDate) + .Ignore(x => x.Details) + ; + } + +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Requests/ContainerRequestMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Requests/ContainerRequestMapperProfile.cs new file mode 100644 index 000000000..3d34447b1 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Requests/ContainerRequestMapperProfile.cs @@ -0,0 +1,69 @@ +using AutoMapper; +using Volo.Abp.AutoMapper; +using Win_in.Sfs.Wms.Inventory.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Event; + +using Win_in.Sfs.Shared.Application; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Wms.Store.Application.Contracts; + +public partial class StoreEventAutoMapperProfile : Profile +{ + private void ContainerRequestMapperProfile() + { + CreateMap() + .ForMember(x => x.ContainerRequestNumber, y => y.MapFrom(d => d.Number)) + .ForMember(x => x.ContainerType, y => y.MapFrom(d => d.ContainerType)) + .ForMember(x => x.SpecificationsType, y => y.MapFrom(d => d.SpecificationsType)) + .ForMember(x => x.IsAutoComplete, y => y.MapFrom(d => d.AutoCompleteJob)) + .ForMember(x => x.JobType, y => y.MapFrom(d => EnumJobType.ContainerTransferJob)) + .ForMember(x => x.JobStatus, y => y.MapFrom(d => EnumJobStatus.Open)) + .Ignore(x => x.WarehouseCode) + .Ignore(x => x.UpStreamJobNumber) + .Ignore(x => x.JobDescription) + .Ignore(x => x.WorkGroupCode) + .Ignore(x => x.Priority) + .Ignore(x => x.PriorityIncrement) + .Ignore(x => x.AcceptUserId) + .Ignore(x => x.AcceptUserName) + .Ignore(x => x.AcceptTime) + .Ignore(x => x.CompleteUserId) + .Ignore(x => x.CompleteUserName) + .Ignore(x => x.CompleteTime) + .Ignore(x => x.Details) + ; + + CreateMap() + .ForMember(x => x.ContainerRequestNumber, y => y.MapFrom(d => d.Number)) + .Ignore(x => x.JobNumber) + .Ignore(x => x.Confirmed) + .Ignore(x => x.Details); + + CreateMap() + .ForMember(x => x.FromContainerCode, y => y.MapFrom(d => d.ContainerCode)) + .ForMember(x => x.FromLocationCode, y => y.MapFrom(d => d.LocationCode)) + .ForMember(x => x.FromLocationErpCode, y => y.MapFrom(d => d.LocationErpCode)) + .ForMember(x => x.FromWarehouseCode, y => y.MapFrom(d => d.WarehouseCode)) + .ForMember(x => x.FromLocationArea, y => y.MapFrom(d => d.LocationArea)) + .ForMember(x => x.FromLocationGroup, y => y.MapFrom(d => d.LocationGroup)) + .ForMember(x => x.FromLot, y => y.MapFrom(d => d.Lot)) + .ForMember(x => x.FromPackingCode, y => y.MapFrom(d => d.PackingCode)) + .ForMember(x => x.FromStatus, y => y.MapFrom(d => d.Status)) + .ForMember(x => x.FromWarehouseCode, y => y.MapFrom(d => d.WarehouseCode)) + .ForMember(x => x.ToContainerCode, y => y.MapFrom(d => d.ContainerCode)) + .ForMember(x => x.ToLocationCode, y => y.MapFrom(d => d.LocationCode)) + .ForMember(x => x.ToLocationErpCode, y => y.MapFrom(d => d.LocationErpCode)) + .ForMember(x => x.ToWarehouseCode, y => y.MapFrom(d => d.WarehouseCode)) + .ForMember(x => x.ToLocationArea, y => y.MapFrom(d => d.LocationArea)) + .ForMember(x => x.ToLocationGroup, y => y.MapFrom(d => d.LocationGroup)) + .ForMember(x => x.ToLot, y => y.MapFrom(d => d.Lot)) + .ForMember(x => x.ToPackingCode, y => y.MapFrom(d => d.PackingCode)) + .ForMember(x => x.ToStatus, y => y.MapFrom(d => d.Status)) + .ForMember(x => x.ToWarehouseCode, y => y.MapFrom(d => d.WarehouseCode)) + .Ignore(t => t.StdPackQty) + .IgnoreIHasRecommendAndHandledFrom(); + + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Requests/MaterialRequestAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Requests/MaterialRequestAutoMapperProfile.cs index 85bb07126..63046f1e2 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Requests/MaterialRequestAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/AutoMapperProfiles/Requests/MaterialRequestAutoMapperProfile.cs @@ -123,9 +123,11 @@ public partial class StoreEventAutoMapperProfile : Profile .Ignore(x => x.PlannedSplitRule) .Ignore(x => x.DeliveryQty) .Ignore(x => x.RequestLocationCode) - .Ignore(x => x.ToLocationCode) + .Ignore(x => x.ToLocationCode) .Ignore(x => x.ProdLine) .Ignore(x => x.WorkStation) + .Ignore(x => x.PositionCode) + .Ignore(x => x.RecommendType) .IgnoreIHasRecommendAndHandledFrom(); } diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Jobs/ContainerJobEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Jobs/ContainerJobEventHandler.cs new file mode 100644 index 000000000..1c3f524e6 --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Jobs/ContainerJobEventHandler.cs @@ -0,0 +1,61 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Volo.Abp.EventBus; +using Volo.Abp.Uow; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.Event; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; +using Win_in.Sfs.Wms.Store.Domain.Shared; + +namespace Win_in.Sfs.Wms.Store.Event.BusinessJob; + +public class ContainerJobEventHandler : + StoreEventHandlerBase + , ILocalEventHandler> +{ + + private readonly IContainerNoteAppService _ContainerNoteAppService; + private readonly ILocationAppService _locationAppService; + + public ContainerJobEventHandler(IContainerNoteAppService ContainerNoteAppService, ILocationAppService locationAppService) + { + _ContainerNoteAppService = ContainerNoteAppService; + _locationAppService = locationAppService; + } + + /// + /// 执行后 + /// + /// + /// + [UnitOfWork] + public virtual async Task HandleEventAsync(SfsCompletedEntityEventData eventData) + { + var entity = eventData.Entity; + var ContainerNote = await BuildContainerNoteAsync(entity).ConfigureAwait(false); + await _ContainerNoteAppService.CreateAsync(ContainerNote).ConfigureAwait(false); + } + + #region 私有 + + /// + /// 创建记录实体 + /// + /// + /// + private async Task BuildContainerNoteAsync(ContainerJob entity) + { + var ContainerNoteCreateInput = ObjectMapper.Map(entity); + ContainerNoteCreateInput.JobNumber = entity.Number; + ContainerNoteCreateInput.Confirmed = true; + ContainerNoteCreateInput.ConfirmTime=DateTime.Now; + + return ContainerNoteCreateInput; + } + + #endregion +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Jobs/ProductionRecycleJobEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Jobs/ProductionRecycleJobEventHandler.cs new file mode 100644 index 000000000..8e6c7fc5b --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Jobs/ProductionRecycleJobEventHandler.cs @@ -0,0 +1,75 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Volo.Abp.EventBus; +using Volo.Abp.Uow; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.Event; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Event.BusinessJob; + + +public class ProductionRecycleJobEventHandler : + StoreEventHandlerBase +, ILocalEventHandler> +, ILocalEventHandler> +{ + private readonly IProductRecycleNoteAppService _productRecycleNoteAppService; + + public ProductionRecycleJobEventHandler( + IProductRecycleNoteAppService productRecycleNoteAppService + ) + { + _productRecycleNoteAppService = productRecycleNoteAppService; + } + + [UnitOfWork] + public virtual async Task HandleEventAsync(SfsCreatedEntityEventData eventData) + { + var entity = eventData.Entity; + + if (entity.IsAutoComplete) + { + entity.CompleteTime = Clock.Now; + entity.JobStatus = EnumJobStatus.Done; + + foreach (var detail in eventData.Entity.Details) + { + detail.SetHandledFromRecommend(); + } + + var note = BuildProductionReturnNote(entity); + await _productRecycleNoteAppService.CreateAsync(note).ConfigureAwait(false); + } + } + + [UnitOfWork] + public virtual async Task HandleEventAsync(SfsCompletedEntityEventData eventData) + { + var entity = eventData.Entity; + + var productRecycleNote = BuildProductionReturnNote(entity); + await _productRecycleNoteAppService.CreateAsync(productRecycleNote).ConfigureAwait(false); + + } + + private ProductRecycleNoteEditInput BuildProductionReturnNote(ProductRecycleJob entity) + { + var input = ObjectMapper.Map(entity); + + + input.Details = new List(); + + foreach (var detail in entity.Details.Where(detail => detail.HandledQty != 0)) + { + var inputDetail = ObjectMapper.Map(detail); + + input.Details.Add(inputDetail); + } + + return input; + } +} diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ContainerRequestEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ContainerRequestEventHandler.cs new file mode 100644 index 000000000..97219e3ee --- /dev/null +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ContainerRequestEventHandler.cs @@ -0,0 +1,192 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Threading.Tasks; +using Volo.Abp; +using Volo.Abp.EventBus; +using Volo.Abp.Uow; +using Win_in.Sfs.Basedata.Application.Contracts; +using Win_in.Sfs.Shared.Domain.Shared; +using Win_in.Sfs.Shared.Event; +using Win_in.Sfs.Wms.Inventory.Application.Contracts; +using Win_in.Sfs.Wms.Store.Application.Contracts; +using Win_in.Sfs.Wms.Store.Domain; + +namespace Win_in.Sfs.Wms.Store.Event.BusinessRequest; + +public class ContainerRequestEventHandler + : StoreEventHandlerBase + , ILocalEventHandler> + , ILocalEventHandler> + , ILocalEventHandler> + , ILocalEventHandler>> + +{ + private readonly IContainerNoteAppService _containerNoteApp; + private readonly IContainerJobAppService _containerJobApp; + private readonly IEquipmentLocAppService _equipmentLocApp; + + + private readonly IContainerRequestManager _containerRequestManager; + + public ContainerRequestEventHandler( + IContainerNoteAppService containerNoteApp, + IContainerJobAppService containerJobApp, + IEquipmentLocAppService equipmentLocApp, + IContainerRequestManager containerRequestManager) + { + _containerNoteApp = containerNoteApp; + _containerJobApp = containerJobApp; + _equipmentLocApp= equipmentLocApp; + _containerRequestManager = containerRequestManager; + } + + + /// + /// 创建后 + /// + /// Event data + [UnitOfWork] + public async Task HandleEventAsync(SfsCreatedEntityEventData eventData) + { + var entity = eventData.Entity; + + //if (entity.AutoSubmit) + //{ + // await _containerRequestManager.SubmitAsync(entity).ConfigureAwait(false); + //} + } + + /// + /// 批量创建后 + /// + /// Event data + [UnitOfWork] + public async Task HandleEventAsync(SfsCreatedEntityEventData> eventData) + { + var entitys = eventData.Entity; + foreach (var entity in entitys) + { + if (entity.AutoSubmit) + { + await _containerRequestManager.SubmitAsync(entity).ConfigureAwait(false); + } + } + } + + /// + /// 审批后 + /// + /// + /// + [UnitOfWork] + public virtual async Task HandleEventAsync(SfsAbortedEntityEventData eventData) + { + var entity = eventData.Entity; + + //东阳特殊逻辑 + if (!entity.DirectCreateNote) + { + + } + } + + /// + /// 执行后 + /// + /// + /// + [UnitOfWork] + public virtual async Task HandleEventAsync(SfsHandledEntityEventData eventData) + { + var entity = eventData.Entity; + + //东阳特殊逻辑 + if (entity.DirectCreateNote) + { + var noteCreateInput = await BuildContainerNoteAsync(entity).ConfigureAwait(false); + await _containerNoteApp.CreateAsync(noteCreateInput).ConfigureAwait(false); + } + else + { + var containerJobCreateInputs = await BuildContainerJobsAsync(entity).ConfigureAwait(false); + await _containerJobApp.CreateAsync(containerJobCreateInputs).ConfigureAwait(false); + } + } + + + #region 私有 + + + private async Task BuildContainerNoteAsync(ContainerRequest request) + { + + var createInput = ObjectMapper.Map(request); + + + ContainerNoteDetailInput detail=new ContainerNoteDetailInput(); + createInput.Details = new List(); + detail.ToLocationCode = request.RequestLocationCode; + + detail.FromLocationCode = "123"; + detail.FromPackingCode = "123"; + detail.ToPackingCode = "123"; + detail.FromLot = "123"; + detail.ToLot = "123"; + detail.FromLocationErpCode = "123"; + detail.FromWarehouseCode = "123"; + detail.ToLocationErpCode = "123"; + detail.ToWarehouseCode = "123"; + detail.Uom = "123"; + detail.ItemCode = "123"; + detail.ItemName = "123"; + + //var container = await _equipmentLocApp.GetByCodeAsync(detail.ToLocationCode).ConfigureAwait(false); + + //if (container != null) + //{ + // detail.ItemCode = container.Code; + //} + + createInput.Details.Add(detail); + + return createInput; + } + + + + private async Task BuildContainerJobsAsync(ContainerRequest request) + { + + var createInput = ObjectMapper.Map(request); + + createInput.WarehouseCode = "T8"; + + ContainerJobDetailInput detail=new ContainerJobDetailInput(); + + detail.FromLocationCode = "123"; + detail.ToLocationCode = "123"; + + detail.ItemCode = "123"; + detail.ItemName = "123"; + detail.RecommendPackingCode = "123"; + detail.RecommendLot = "123"; + detail.RecommendFromLocationCode = "123"; + detail.RecommendFromLocationErpCode = "123"; + detail.Uom = "123"; + + + createInput.Details.Add(detail); + + + + + return createInput ; + } + + #endregion +} + diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/MaterialRequestEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/MaterialRequestEventHandler.cs index 02937f8ff..4f9c8d67f 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/MaterialRequestEventHandler.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/MaterialRequestEventHandler.cs @@ -52,10 +52,10 @@ public class MaterialRequestEventHandler { var entity = eventData.Entity; - if (entity.AutoSubmit) - { - await _materialRequestManager.SubmitAsync(entity).ConfigureAwait(false); - } + //if (entity.AutoSubmit) + //{ + // await _materialRequestManager.SubmitAsync(entity).ConfigureAwait(false); + //} } /// @@ -244,6 +244,8 @@ public class MaterialRequestEventHandler detail.RequestLocationCode = materialRequestDetail.ToLocationCode; detail.WorkStation = materialRequestDetail.WorkStation; detail.ExpiredTime = materialRequestDetail.ExpiredTime; + detail.PositionCode = materialRequestDetail.PositionCode; + detail.RecommendType = materialRequestDetail.RecommendType; detail.RecommendPackingCode = balance.PackingCode; detail.RecommendContainerCode = balance.ContainerCode; diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ProductRecycleRequestEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ProductRecycleRequestEventHandler.cs index 2e0b3a9f8..d2c3ca821 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ProductRecycleRequestEventHandler.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Requests/ProductRecycleRequestEventHandler.cs @@ -12,6 +12,9 @@ using Win_in.Sfs.Wms.Store.Event.BusinessRequest; namespace Win_in.Sfs.Wms.Store.Event.Stores; using Application.Contracts; +using Volo.Abp.ObjectMapping; +using Win_in.Sfs.Wms.Inventory.Application.Contracts; +using static Win_in.Sfs.Wms.Store.Domain.Shared.StoreSettings; public class ProductRecycleRequestEventHandler : StoreEventHandlerBase @@ -19,21 +22,32 @@ public class ProductRecycleRequestEventHandler , ILocalEventHandler> , ILocalEventHandler>> { + private readonly IProductRecycleJobAppService _productRecycleJobAppService; private readonly IProductRecycleNoteAppService _productRecycleNoteApp; private readonly IBackFlushNoteAppService _backFlushNoteApp; private readonly IBomAppService _bomApp; private readonly IProductRecycleRequestManager _productRecycleRequestManager; + private readonly IBalanceAppService _balanceAppService; + private readonly ILocationAppService _locationAppService; public ProductRecycleRequestEventHandler( IProductRecycleNoteAppService productRecycleNoteApp, + IBalanceAppService balanceAppService, + ILocationAppService locationAppService, IBackFlushNoteAppService backFlushNoteApp, - IBomAppService bomApp, IProductRecycleRequestManager - productRecycleRequestManager) + IBomAppService bomApp, + IProductRecycleRequestManager productRecycleRequestManager, + IProductRecycleJobAppService productRecycleJobAppService + ) { _productRecycleNoteApp = productRecycleNoteApp; _backFlushNoteApp = backFlushNoteApp; _bomApp = bomApp; _productRecycleRequestManager = productRecycleRequestManager; + _balanceAppService = balanceAppService; + _locationAppService = locationAppService; + _productRecycleJobAppService = productRecycleJobAppService; + } /// @@ -60,6 +74,8 @@ public class ProductRecycleRequestEventHandler var entitys = eventData.Entity; foreach (var entity in entitys) { + entity.AutoAgree = true; + entity.DirectCreateNote = false; if (entity.AutoSubmit) { await _productRecycleRequestManager.SubmitAsync(entity).ConfigureAwait(false); @@ -77,15 +93,125 @@ public class ProductRecycleRequestEventHandler var productRecycle = await BuildProductRecycleNoteAsync(entity).ConfigureAwait(false); await _productRecycleNoteApp.CreateAsync(productRecycle).ConfigureAwait(false); - - // var backFlushs = await BuildFlushNotesAsync(entity); - // - // await _backFlushNoteApp.CreateManyAsync(backFlushs); + + } + else + { + var productRecycleJobs = await BuildProductRecycleJobsAsync(entity).ConfigureAwait(false); + await _productRecycleJobAppService.CreateManyAsync(productRecycleJobs).ConfigureAwait(false); } } #region 私有 + private async Task> BuildProductRecycleJobsAsync(ProductRecycleRequest request) + { + var jobs = new List(); + + var transactionType = await TransactionTypeAclService.GetByTransTypeAsync(EnumTransType.ProductRecycle, EnumTransSubType.None).ConfigureAwait(false);//库存事务 + + var job = ObjectMapper.Map(request); + + //job.Details = new List(); + + foreach (var detail in request.Details) + { + + //创建详情 + var jobDetails = await BuildProductRecycleInputsAsync(request, detail, transactionType).ConfigureAwait(false); + if (!jobDetails.Any()) + { + continue; + } + + var fromLocationCode = jobDetails[0].LocationCode; + var fromLocation = await _locationAppService.GetByCodeAsync(fromLocationCode).ConfigureAwait(false); + job = BuildProductRecycleJobCreateInput(request, fromLocation); + job.Details.Clear(); + jobs.Add(job); + job.Details.AddRange(jobDetails); + + } + + return jobs; + } + + private ProductRecycleJobEditInput BuildProductRecycleJobCreateInput(ProductRecycleRequest productRecycleRequest, LocationDTO fromLocation) + { + ProductRecycleJobEditInput job; + job = ObjectMapper.Map(productRecycleRequest); + job.JobType = EnumJobType.ProductionReturnJob; + job.JobStatus = EnumJobStatus.Open; + job.WorkGroupCode = fromLocation.WorkGroupCode; + job.WarehouseCode = fromLocation.WarehouseCode; + job.Worker = productRecycleRequest.Worker; + job.Workshop= fromLocation.AreaCode; + if (job.Worker==null) + { + job.Worker = "admin"; + } + //job.MaterialRequestNumber = productRecycleRequest.Number; + return job; + } + + private async Task> BuildProductRecycleInputsAsync(ProductRecycleRequest productRecycleRequest, + ProductRecycleRequestDetail productRecycleRequestDetail, TransactionTypeDTO transactionType) + { + var jobDetails = new List(); + //var input = new RecommendBalanceRequestInput() + //{ + // ItemCode = productRecycleRequestDetail.ItemCode, + // Qty = productRecycleRequestDetail.Qty, + // LocationTypes = transactionType.OutLocationTypes, + // LocationAreas = new List { productRecycleRequestDetail.LocationArea }, + // Statuses = transactionType.OutInventoryStatuses, + //}; + //获取推荐库存 + var recommendList = await _balanceAppService.GetListByItemCodeAsync(productRecycleRequestDetail.ItemCode).ConfigureAwait(false); + //没有推荐库存时 跳过此明细 不生成任务 + if (recommendList.Count != 0) + { + foreach (var recommend in recommendList) + { + if(recommend.LocationCode== productRecycleRequestDetail.LocationCode) + { + var detail = await BuildProductRecycleJobDetailAsync(productRecycleRequestDetail, recommend).ConfigureAwait(false); + + jobDetails.Add(detail); + } + + + } + } + return jobDetails; + } + + private async Task BuildProductRecycleJobDetailAsync(ProductRecycleRequestDetail productRecycleRequestDetail, BalanceDTO balance) + { + + var detail = ObjectMapper.Map(productRecycleRequestDetail); + + detail.RecommendToLocationErpCode = balance.LocationErpCode; + detail.RecommendToLocationCode = balance.LocationCode; + detail.RecommendPackingCode = balance.PackingCode; + detail.RecommendContainerCode = balance.ContainerCode; + detail.RecommendSupplierBatch = balance.SupplierBatch; + detail.RecommendProduceDate = balance.ProduceDate; + detail.RecommendExpireDate = balance.ExpireDate; + detail.RecommendLot = balance.Lot; + detail.RecommendProduceDate = balance.ProduceDate; + detail.RecommendArriveDate = balance.ArriveDate; + detail.RecommendQty = balance.Qty; + detail.Uom = balance.Uom; + + + await Task.CompletedTask.ConfigureAwait(false); + return detail; + + } + + + private async Task BuildProductRecycleNoteAsync(ProductRecycleRequest request) { var createInput = ObjectMapper.Map(request); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/StoreEventAutoMapperProfile.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/StoreEventAutoMapperProfile.cs index 9dfa74f8d..40de8aa9b 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/StoreEventAutoMapperProfile.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/StoreEventAutoMapperProfile.cs @@ -30,7 +30,7 @@ public partial class StoreEventAutoMapperProfile : Profile #endregion #region Jobs - + ContainerJobAutoMapperProfile(); CountJobAutoMapperProfile(); DeliverJobAutoMapperProfile(); InspectJobAutoMapperProfile(); @@ -60,6 +60,7 @@ public partial class StoreEventAutoMapperProfile : Profile CustomerReturnNoteAutoMapperProfile(); DeliverNoteAutoMapperProfile(); DeliverRequestMapperProfile(); + ContainerRequestMapperProfile(); InspectNoteAutoMapperProfile(); InventoryTransferNoteAutoMapperProfile(); IsolationNoteAutoMapperProfile(); diff --git a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Transactions/ItemTransformNoteEventHandler.cs b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Transactions/ItemTransformNoteEventHandler.cs index c33adc601..601b86bbd 100644 --- a/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Transactions/ItemTransformNoteEventHandler.cs +++ b/be/Modules/Store/src/Win_in.Sfs.Wms.Store.Event/Transactions/ItemTransformNoteEventHandler.cs @@ -1,4 +1,5 @@ using System.Collections.Generic; +using System.Linq; using System.Threading.Tasks; using Volo.Abp.EventBus; using Volo.Abp.Uow; @@ -28,10 +29,11 @@ public class ItemTransformNoteEventHandler private async Task AddTransactionsAsync(ItemTransformNote note) { var inboundTransactions = new List(); - - inboundTransactions.AddRange(BuildTransactions(note)); - + var noTransactions = new List(); + inboundTransactions.AddRange(NewBuildTransactions(note));//原料+混拌料 + noTransactions.AddRange(BuildNoTransactions(note));//粉碎料 await TransactionAppService.AddManyAsync(inboundTransactions).ConfigureAwait(false); + await TransactionAppService.AddManyEmptyAsync(noTransactions).ConfigureAwait(false); } @@ -46,14 +48,16 @@ public class ItemTransformNoteEventHandler { var inboundTransactions = new List(); - + var noTransactions = new List(); //如果要做库存事务汇总,可以修改此处 foreach (var note in notes) { - inboundTransactions.AddRange(BuildTransactions(note)); + inboundTransactions.AddRange(NewBuildTransactions(note));//原料+混拌料 + noTransactions.AddRange(BuildNoTransactions(note));//粉碎料 } await TransactionAppService.AddManyAsync(inboundTransactions).ConfigureAwait(false); + await TransactionAppService.AddManyEmptyAsync(noTransactions).ConfigureAwait(false); } private static List BuildTransactions(ItemTransformNote note) @@ -131,4 +135,151 @@ public class ItemTransformNoteEventHandler return transactions; } + /// + /// 新回收料库存方法 + /// + /// + /// + + private static List NewBuildTransactions(ItemTransformNote note) + { + var transactions = new List(); + + //根据调整记录,构造库存转移记录(只添加原料得) + foreach (var detail in note.Details.Where(r => r.Remark == "原料")) + { + var transactionOut = new TransactionEditInput() + { + Worker = note.Worker, + JobNumber = note.JobNumber, + DocNumber = note.Number, + TransType = Type, + TransSubType = SubType, + TransInOut = EnumTransInOut.Out, + LocationArea = detail.FromLocationArea, + LocationGroup = detail.FromLocationGroup, + LocationErpCode = detail.FromLocationErpCode, + PackingCode = detail.FromPackingCode, + ItemCode = detail.ItemCode, + Lot = detail.FromLot, + Status = detail.FromStatus, + WarehouseCode = detail.FromWarehouseCode, + LocationCode = detail.FromLocationCode, + ContainerCode = detail.FromContainerCode, + SupplierBatch = detail.FromSupplierBatch, + ArriveDate = detail.FromArriveDate, + ProduceDate = detail.FromProduceDate, + ExpireDate = detail.FromExpireDate, + ItemName = detail.ItemName, + ItemDesc1 = detail.ItemDesc1, + ItemDesc2 = detail.ItemDesc2, + Uom = detail.Uom, + Qty = -detail.FromQty, + }; + + transactions.Add(transactionOut); + } + //混拌料添加事务 + var detailfirst = note.Details.First(r => r.Remark == "原料"); + var transactionIn = new TransactionEditInput() + { + Worker = note.Worker, + JobNumber = note.JobNumber, + DocNumber = note.Number, + TransType = Type, + TransSubType = SubType, + TransInOut = EnumTransInOut.In, + + PackingCode = detailfirst.ToPackingCode, + ItemCode = detailfirst.ToItemCode, + Lot = detailfirst.ToLot, + Status = detailfirst.ToStatus, + LocationArea = detailfirst.ToLocationArea, + LocationGroup = detailfirst.ToLocationGroup, + LocationErpCode = detailfirst.ToLocationErpCode, + WarehouseCode = detailfirst.ToWarehouseCode, + LocationCode = detailfirst.ToLocationCode, + ContainerCode = detailfirst.ToContainerCode, + SupplierBatch = detailfirst.ToSupplierBatch, + ArriveDate = detailfirst.ToArriveDate, + ProduceDate = detailfirst.ToProduceDate, + ExpireDate = detailfirst.ToExpireDate, + ItemName = detailfirst.ItemName, + ItemDesc1 = detailfirst.ItemDesc1, + ItemDesc2 = detailfirst.ItemDesc2, + Uom = detailfirst.Uom, + Qty = detailfirst.ToQty, + }; + transactions.Add(transactionIn); + + return transactions; + } + private static List BuildNoTransactions(ItemTransformNote note) + { + var transactions = new List(); + + //根据调整记录,构造库存转移记录(只添加原料得) + foreach (var detail in note.Details.Where(r => r.Remark != "原料")) + { + var transactionOut = new TransactionEditInput() + { + Worker = note.Worker, + JobNumber = note.JobNumber, + DocNumber = note.Number, + TransType = Type, + TransSubType = SubType, + TransInOut = EnumTransInOut.Out, + LocationArea = detail.FromLocationArea, + LocationGroup = detail.FromLocationGroup, + LocationErpCode = detail.FromLocationErpCode, + PackingCode = detail.FromPackingCode, + ItemCode = detail.ItemCode, + Lot = detail.FromLot, + Status = detail.FromStatus, + WarehouseCode = detail.FromWarehouseCode, + LocationCode = detail.FromLocationCode, + ContainerCode = detail.FromContainerCode, + SupplierBatch = detail.FromSupplierBatch, + ArriveDate = detail.FromArriveDate, + ProduceDate = detail.FromProduceDate, + ExpireDate = detail.FromExpireDate, + ItemName = detail.ItemName, + ItemDesc1 = detail.ItemDesc1, + ItemDesc2 = detail.ItemDesc2, + Uom = detail.Uom, + Qty = -detail.FromQty, + }; + transactions.Add(transactionOut); + var transactionIn = new TransactionEditInput() + { + Worker = note.Worker, + JobNumber = note.JobNumber, + DocNumber = note.Number, + TransType = Type, + TransSubType = SubType, + TransInOut = EnumTransInOut.In, + LocationArea = detail.FromLocationArea, + LocationGroup = detail.FromLocationGroup, + LocationErpCode = detail.FromLocationErpCode, + PackingCode = detail.FromPackingCode, + ItemCode = detail.ItemCode, + Lot = detail.FromLot, + Status = detail.FromStatus, + WarehouseCode = detail.FromWarehouseCode, + LocationCode = detail.FromLocationCode, + ContainerCode = detail.FromContainerCode, + SupplierBatch = detail.FromSupplierBatch, + ArriveDate = detail.FromArriveDate, + ProduceDate = detail.FromProduceDate, + ExpireDate = detail.FromExpireDate, + ItemName = detail.ItemName, + ItemDesc1 = detail.ItemDesc1, + ItemDesc2 = detail.ItemDesc2, + Uom = detail.Uom, + Qty = detail.FromQty, + }; + transactions.Add(transactionIn); + } + return transactions; + } } diff --git a/be/Modules/Store/src/src.rar b/be/Modules/Store/src/src.rar new file mode 100644 index 000000000..b17461426 Binary files /dev/null and b/be/Modules/Store/src/src.rar differ diff --git a/build/src/docker/publish/conf/settings/appsettings.Development.json b/build/src/docker/publish/conf/settings/appsettings.Development.json index 55f832e94..675ae449e 100644 --- a/build/src/docker/publish/conf/settings/appsettings.Development.json +++ b/build/src/docker/publish/conf/settings/appsettings.Development.json @@ -74,24 +74,24 @@ // "Store": "Server=localhost,21195;Database=Wms;Uid=sa;Pwd=aA123456!;timeout=6000;" // }, "ConnectionStrings": { - "AbpAuditLogging": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "AbpBackgroundJobs": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "AbpBlobStoring": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "AbpFeatureManagement": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "AbpIdentity": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "AbpIdentityServer": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "AbpPermissionManagement": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "AbpSettingManagement": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "AbpTenantManagement": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "Auth": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "Basedata": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "DataExchange": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "FileStorage": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "Inventory": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "Job": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "Label": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "Message": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", - "Store": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;" + "AbpAuditLogging": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpBackgroundJobs": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpBlobStoring": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpFeatureManagement": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpIdentity": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpIdentityServer": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpPermissionManagement": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpSettingManagement": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "AbpTenantManagement": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Auth": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Basedata": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "DataExchange": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "FileStorage": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Inventory": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Job": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Label": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Message": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;", + "Store": "Server=dev.ccwin-in.com,13319;Database=WMS_DongYang_Main_CC;uid=ccwin-in;pwd=Microsoft@2022;timeout=6000;" }, "IdentityClients": { "Default": { @@ -114,7 +114,7 @@ "BaseUrl": "http://dev.ccwin-in.com:60083/" }, "BaseData": { - "BaseUrl": "http://dev.ccwin-in.com:60084/" + "BaseUrl": "http://localhost:59094/" }, "Default": { "BaseUrl": "http://dev.ccwin-in.com:60083/"